Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement CyclePasteAction. #2885

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

sandipchitale
Copy link

@sandipchitale sandipchitale commented Dec 3, 2024

I am trying to contribute an action which will supplement the Paste from History... action of JetBrains IDEs. Here is my idea:
My action will do the following:

  • It will check if the same action was invoked within the past second duration.
    • If it was not:
      • It will simply behave like the standard paste action and paste the first item in the history. Reset an index counter to 0.
    • If it was:
      • It will first invoke the undo action to undo the last paste, then increment the index and then paste the next item in the clipboard history.

This basically behaves like a cycle paste from the history without invoking the Clipboard History chooser.

Of course this works best if you bind the action to some keyboard shortcut and thus are able to invoke again and again with less than one second gap.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant