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

Add "Copy URL" context menu option when hovering over a URL #219

Merged
merged 2 commits into from Dec 5, 2017

Conversation

Projects
None yet
2 participants
@pp3345
Contributor

pp3345 commented Nov 24, 2017

Many IM clients (e. g. Pidgin) offer the convenience option to copy a URL without selecting it first when right-clicking on it. This PR adds that feature to Dino.

image

pp3345 and others added some commits Nov 24, 2017

@fiaxh

This comment has been minimized.

Show comment
Hide comment
@fiaxh

fiaxh Dec 4, 2017

Member

Your code depended on "Copy" being translated in order to correctly insert the new item. On the other hand, most of the default items (Cut, Paste, Delete) won't work in anyways, as the textview is not editable. I rewrote the code to remove the default items and insert only the ones fitting ones.

Member

fiaxh commented Dec 4, 2017

Your code depended on "Copy" being translated in order to correctly insert the new item. On the other hand, most of the default items (Cut, Paste, Delete) won't work in anyways, as the textview is not editable. I rewrote the code to remove the default items and insert only the ones fitting ones.

@fiaxh fiaxh merged commit dc2dde5 into dino:master Dec 5, 2017

@pp3345

This comment has been minimized.

Show comment
Hide comment
@pp3345

pp3345 Dec 8, 2017

Contributor

I also thought that searching through the list of menu items and looking for an item named "Copy" (with its translation) is a bit ugly, however, I didn't find another solution to insert the "Copy URL" item directly after the "Copy" item. However, if there is no translated "Copy" item, the code would have put the "Copy URL" item at the end of the list, so that wouldn't have caused too many problems. Removing the unused default items instead is a better idea though.

Thanks for merging!

Contributor

pp3345 commented Dec 8, 2017

I also thought that searching through the list of menu items and looking for an item named "Copy" (with its translation) is a bit ugly, however, I didn't find another solution to insert the "Copy URL" item directly after the "Copy" item. However, if there is no translated "Copy" item, the code would have put the "Copy URL" item at the end of the list, so that wouldn't have caused too many problems. Removing the unused default items instead is a better idea though.

Thanks for merging!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment