Don't show overwrite dialog if file name is empty

Review Request #120127 - Created Sept. 10, 2014 and submitted

Information
Ignaz Forster
kdelibs
Reviewers
kdelibs

Programs using KFileDialog's setConfirmOverwrite(true) (e.g. LibreOffice with KDE4 integration, Mozilla products with KDE4 integration, several components of the PIM suite) will trigger the following strange behaviour:
If the file name in the save file dialog is empty and the user selects "Save", the dialog will ask if you want to overwrite the current directory (instead of just ignoring the empty input).

By moving the query below the directory checks the order is correct again, showing the overwrite confirmation dialog only if the field contains a unique filename.

Looking at the code this also affects Frameworks 5 / kio, though I haven't tested it yet.


  
Ignaz Forster
David Faure
Ignaz Forster
Review request changed

Status: Closed (submitted)

Change Summary:

Submitted with commit 92884891cbb38d429c219f6cf25f1a3f58b66078 by Albert Astals Cid on behalf of Ignaz Forster to branch master.
Loading...