Review Request 125293: Fix drag'n'drop extraction of CLI plugins
Ragnar Thomsen
rthomsen6 at gmail.com
Mon Sep 21 19:27:21 UTC 2015
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/125293/
-----------------------------------------------------------
(Updated Sept. 21, 2015, 7:27 p.m.)
Status
------
This change has been marked as submitted.
Review request for KDE Utils, Elvis Angelaccio and Raphael Kubo da Costa.
Changes
-------
Submitted with commit 7c025dd5765c41957787493786248157f29b4e13 by Ragnar Thomsen to branch Applications/15.08.
Bugs: 208384
http://bugs.kde.org/show_bug.cgi?id=208384
Repository: ark
Description
-------
This fixes drag'n'drop extraction of selected entries from Ark to e.g. Dolphin. Previously, the entries would be extracted with full path, which is not what the user expects and not how libarchive handles tar-based archives. This was due to the CLI plugins not supporting root nodes (i.e. removing a part of the path). This is now circumvented by extracting to a QTemporaryDir, removing the root node from the path, and finally moving the files to their final destination. The moving to final destination is done in a new member function in CliInterface (moveToFinalDest). This function checks if the destination file exists and prompts the user for action if that is the case.
The emit finished() call, which signals that the extract/list/delete/add-job has ended, was previously done in CliInterface::processFinished(). The call had to be moved to CliInterface::copyFiles()/list()/deleteFiles()/addFiles(), respectively. Otherwise the jobs would be completed after extracting to the temporary dir and before moving them to their final destination. This was also necessary for the emit userQuery() call in moveToFinalDest().
Things to consider:
QTemporaryDir creates a directory in /tmp. What happens/should happen if this partition fills up?
Diffs
-----
kerfuffle/cliinterface.h 052851a
kerfuffle/cliinterface.cpp 1e936a6
Diff: https://git.reviewboard.kde.org/r/125293/diff/
Testing
-------
Extracting files from zip, 7z and rar archives by selecting and dragging them to Dolphin.
Thanks,
Ragnar Thomsen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-utils-devel/attachments/20150921/5afe7016/attachment.html>
More information about the Kde-utils-devel
mailing list