D13145: Check if destination exists also when pasting binary data

2018-06-03 Thread Elvis Angelaccio
This revision was automatically updated to reflect the committed changes.
Closed by commit R241:b73355da3f5b: Check if destination exists also when 
pasting binary data (authored by elvisangelaccio).

REPOSITORY
  R241 KIO

CHANGES SINCE LAST UPDATE
  https://phabricator.kde.org/D13145?vs=34962=35373

REVISION DETAIL
  https://phabricator.kde.org/D13145

AFFECTED FILES
  src/widgets/paste.cpp

To: elvisangelaccio, dfaure
Cc: kde-frameworks-devel, michaelh, ngraham, bruns


D13145: Check if destination exists also when pasting binary data

2018-05-29 Thread David Faure
dfaure accepted this revision.
This revision is now accepted and ready to land.

REPOSITORY
  R241 KIO

BRANCH
  fix-image-pasting (branched from master)

REVISION DETAIL
  https://phabricator.kde.org/D13145

To: elvisangelaccio, dfaure
Cc: kde-frameworks-devel, michaelh, ngraham, bruns


D13145: Check if destination exists also when pasting binary data

2018-05-27 Thread Elvis Angelaccio
elvisangelaccio created this revision.
elvisangelaccio added a reviewer: dfaure.
Restricted Application added a project: Frameworks.
Restricted Application added a subscriber: kde-frameworks-devel.
elvisangelaccio requested review of this revision.

REVISION SUMMARY
  Currently we check whether the destination URL exists only if we are
  pasting text (or if the mimedata has only one format).
  
  If we are pasting e.g. images copied from Spectacle, we unconditionally
  overwrite the destination URL.
  
  This patch moves the StatJob+RenameDialog from `getNewFileName()` to a
  new `getDestinationUrl()` function, which we can also call from 
`chooseFormatAndUrl()`.
  
  BUG: 394318
  FIXED-IN: 5.47

TEST PLAN
  - Paste some image into an existing file and check the rename dialog.
  - Check that pasting text still shows the rename dialog.

REPOSITORY
  R241 KIO

BRANCH
  fix-image-pasting (branched from master)

REVISION DETAIL
  https://phabricator.kde.org/D13145

AFFECTED FILES
  src/widgets/paste.cpp

To: elvisangelaccio, dfaure
Cc: kde-frameworks-devel, michaelh, ngraham, bruns