Snapshot/SnapWidget.py

branch
5_3_x
changeset 3132
24263e1fdd20
parent 2764
1d85539ac41a
child 3163
9f50365a0870
equal deleted inserted replaced
3131:add94de7d675 3132:24263e1fdd20
392 @pyqtSlot() 392 @pyqtSlot()
393 def on_copyButton_clicked(self): 393 def on_copyButton_clicked(self):
394 """ 394 """
395 Private slot to copy the snapshot to the clipboard. 395 Private slot to copy the snapshot to the clipboard.
396 """ 396 """
397 QApplication.clipboard().setPixmap(self.preview.pixmap()) 397 if not self.__snapshot.isNull():
398 QApplication.clipboard().setPixmap(QPixmap(self.__snapshot))
398 399
399 def __captured(self, pixmap): 400 def __captured(self, pixmap):
400 """ 401 """
401 Private slot to show a preview of the snapshot. 402 Private slot to show a preview of the snapshot.
402 403

eric ide

mercurial