Review Request 129714: Disable rename action from Trash
Elvis Angelaccio
elvis.angelaccio at kde.org
Wed Dec 28 15:30:01 GMT 2016
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/129714/
-----------------------------------------------------------
Review request for Dolphin and Emmanuel Pescosta.
Bugs: 332465
https://bugs.kde.org/show_bug.cgi?id=332465
Repository: dolphin
Description
-------
Dolphin relies on KFileItemListProperties::supportsMoving() to enable/disable the rename action. However, the trash:/ protocol is a corner case because while it supports moving, it explicitly forbids renaming urls from trash:/ to trash:/
```c++
// kio_trash.cpp, line 137
if (oldURL.scheme() == QLatin1String("trash") && newURL.scheme() == QLatin1String("trash")) {
error(KIO::ERR_CANNOT_RENAME, oldURL.toString());
return;
}
```
For this reason, we need to disable the rename action if the view is in the Trash.
BUG: 332465
FIXED-IN: 16.12.1
Diffs
-----
src/dolphinmainwindow.cpp e5103fd42
src/dolphinpart.cpp aa9ab2986
Diff: https://git.reviewboard.kde.org/r/129714/diff/
Testing
-------
F2 from Trash no longer triggers a useless rename job.
Thanks,
Elvis Angelaccio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20161228/b222d083/attachment.htm>
More information about the kfm-devel
mailing list