Browse Source

show message when copy button is pressed

seed_v14
ThomasV 7 years ago
parent
commit
252cb491c8
  1. 7
      gui/qt/util.py

7
gui/qt/util.py

@ -531,8 +531,11 @@ class ButtonsWidget(QWidget):
def addCopyButton(self, app):
self.app = app
f = lambda: self.app.clipboard().setText(str(self.text()))
self.addButton(":icons/copy.png", f, _("Copy to clipboard"))
self.addButton(":icons/copy.png", self.on_copy, _("Copy to clipboard"))
def on_copy(self):
self.app.clipboard().setText(self.text())
QToolTip.showText(QCursor.pos(), _("Text copied to clipboard"), self)
class ButtonsLineEdit(QLineEdit, ButtonsWidget):
def __init__(self, text=None):

Loading…
Cancel
Save