Improve ExtractionDialog
ClosedPublic

Authored by rthomsen on Mar 17 2016, 8:19 PM.

Details

Summary

This enables typing an existing subfolder's name in the location bar and pressing Return/Enter. Previuosly when this was attempted, Ark would extract to baseUrl(). This behavior deviated from a QFileDialog (which we use for Open Dialog), which simply enters the existing subfolder.

Bug 360640

Diff Detail

Repository
R36 Ark
Lint
Lint Skipped
Unit
Unit Tests Skipped
rthomsen updated this revision to Diff 2826.Mar 17 2016, 8:19 PM
rthomsen retitled this revision from to Improve ExtractionDialog.
rthomsen updated this object.
rthomsen edited the test plan for this revision. (Show Details)
rthomsen added a reviewer: elvisangelaccio.
rthomsen set the repository for this revision to R36 Ark.
rthomsen added a project: Ark.
Restricted Application added a subscriber: kde-utils-devel. · View Herald TranscriptMar 17 2016, 8:19 PM
elvisangelaccio requested changes to this revision.Mar 17 2016, 8:48 PM
elvisangelaccio edited edge metadata.

The bugfix works for me!

kerfuffle/extractiondialog.cpp
103

"ExtractioDialog::slotAccepted() called" would be more useful.
Or maybe even drop this debug line?

106

You can save one indentation level here.

if (fileWidget->dirOperator()->selectedItems().isEmpty()) {
   // code for setUrl()
   ...
   return;
}

// code for normal extraction.
...
110

Double ampersand.

112

Maybe QUrl::fromLocalFile() here?

This revision now requires changes to proceed.Mar 17 2016, 8:48 PM
rthomsen updated this revision to Diff 2830.Mar 18 2016, 5:51 AM
rthomsen updated this object.
rthomsen edited edge metadata.

Implement Elvis' suggestions.

rthomsen marked 4 inline comments as done.Mar 18 2016, 5:52 AM
elvisangelaccio accepted this revision.Mar 18 2016, 9:49 AM
elvisangelaccio edited edge metadata.

I tested the patch again and the dialog works as expected.

kerfuffle/extractiondialog.cpp
105

Opening brace on the line above

This revision is now accepted and ready to land.Mar 18 2016, 9:49 AM
This revision was automatically updated to reflect the committed changes.