[ENH] OWPythonScript: dropping and pasting of python scripts#3611
Merged
janezd merged 2 commits intobiolab:masterfrom Mar 1, 2019
Merged
[ENH] OWPythonScript: dropping and pasting of python scripts#3611janezd merged 2 commits intobiolab:masterfrom
janezd merged 2 commits intobiolab:masterfrom
Conversation
Member
Author
|
As @BlazZupan suggested, now, this widgets pop ups a dialog that asks whether to replace the current script or append to it. Another option (that I prefer) is to never ask and always insert the text at the cursor position. |
Codecov Report
@@ Coverage Diff @@
## master #3611 +/- ##
==========================================
+ Coverage 84.24% 84.26% +0.01%
==========================================
Files 370 370
Lines 67475 67565 +90
==========================================
+ Hits 56844 56932 +88
- Misses 10631 10633 +2 |
The current script is replaced (in an undoable way) with the pasted script.
Member
Author
|
We talked about it with @BlazZupan and we decided that if a user drags/pastes in a file, the current script is replaced with that file (there are no pop-up dialogs asking you where to put it as in the first attempt). I took care that undo still works. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue
Drag and drop of files did not work in the Python script widget
Description of changes
Files can be dragged and dropped (or pasted) onto the script editor or widget's control area. Nothing changed for dropping or pasting text.
Includes