New issue
Advanced search Search tips

Issue 688895 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Nov 20
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 3
Type: Bug



Sign in to add a comment

Directory being dragged should not be a drop target

Project Member Reported by yamaguchi@chromium.org, Feb 6 2017

Issue description

Chrome Version: 58.0.3000.0

Steps To Reproduce:
(1) Open a directory or a volume containing a subdirectory.
(2) Start to drag a subdirectory in the file list.
(3) Drop the subdirectory to itself.
(4) Drag the subdirectory again and keep the mouse cursor on the subdirectory for a while.

Expected Result:
(3) The move operation is cancelled without any error.
(4) Nothing happens.

Actual Result:
(3) Error message appears: "Move failed. The file could not be modified."
(4) The Files app navigates into the subdirectory. (just like when hovering on a directory in other places)


- The same happens when doing above with [ctrl] key down. (i.e. copy by drag-drop)
- The error message might not be easy to understand because it just tells the internal operation was failed without the reason. If we were to make it more descriptive, "You cannot move a directory into itself".
- I think this operation should be treated as a cancellation of the drag gesture, thus should not give any error message.
- Moving a directory into itself or its descendant directory is always impossible. Therefore navigating into the directory and its subdirectory by hovering on it may not be helpful for this case.

 

Comment 1 by sashab@chromium.org, Feb 24 2018

Labels: CrOS-FilesApp

Comment 2 by sashab@chromium.org, Feb 28 2018

Labels: -CrOS-FilesApp

Comment 3 by sashab@chromium.org, Apr 12 2018

Status: Available (was: Untriaged)
This should have the non-droppable icon and disable the target during drag-n-drop.
Labels: Files-Fixit-2018 CrOSFilesCategory-UI
Owner: dats@chromium.org
Status: Started (was: Available)
Project Member

Comment 6 by bugdroid1@chromium.org, Nov 20

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/aecd301460d77b75b8d50a32703475e0269a3171

commit aecd301460d77b75b8d50a32703475e0269a3171
Author: Sergei Datsenko <dats@chromium.org>
Date: Tue Nov 20 07:00:10 2018

Disallow drag-and-drop of folders into themselves.

I still don't know what I'm doing, but I'm getting better at it.

BUG= chromium:688895 

Change-Id: Ia05a3506844b888579f4353c02b09b3bf4b95edd
Reviewed-on: https://chromium-review.googlesource.com/c/1341732
Reviewed-by: Luciano Pacheco <lucmult@chromium.org>
Commit-Queue: Sergei Datsenko <dats@chromium.org>
Cr-Commit-Position: refs/heads/master@{#609617}
[modify] https://crrev.com/aecd301460d77b75b8d50a32703475e0269a3171/ui/file_manager/file_manager/foreground/js/file_transfer_controller.js

Status: Fixed (was: Started)

Sign in to add a comment