From 9f61096967eb556b3b6affe9850c31edcffede7f Mon Sep 17 00:00:00 2001 From: gfdgd_xi <3025613752@qq.com> Date: Sat, 15 Apr 2023 19:35:17 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=A4=8D=E5=88=B6=E5=8A=9F?= =?UTF-8?q?=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- deb/DEBIAN/control | 2 +- mainwindow.py | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/deb/DEBIAN/control b/deb/DEBIAN/control index 6a87474..fcfca2a 100755 --- a/deb/DEBIAN/control +++ b/deb/DEBIAN/control @@ -8,7 +8,7 @@ Certainty: possible Check: binaries Type: binary, udeb Priority: optional -Depends: python3, python3-pil, libc6, python3-pil.imagetk, python3-pyquery, aria2, curl, unrar | unrar-free , unzip, python3-requests, python3-pyqt5, python3-psutil, deepin-terminal | mate-terminal | gnome-terminal | xfce4-terminal, python3-dbus, python3-pip, p7zip-full, sudo +Depends: python3, python3-pil, libc6, python3-pil.imagetk, python3-pyquery, aria2, curl, unrar | unrar-free , unzip, python3-requests, python3-pyqt5, python3-psutil, deepin-terminal | mate-terminal | gnome-terminal | xfce4-terminal, python3-dbus, python3-pip, p7zip-full, sudo, python3-pyperclip Recommends: winbind, wimtools, python3-pyqt5.qtwebengine, qemu-user, binfmt-support, qemu-user-static Section: utils Conflicts: spark.deepin-venturi-setter, spark-deepin-wine5-application-packer, spark-deepin-wine-runner-52, spark-deepin-wine-runner diff --git a/mainwindow.py b/mainwindow.py index 352d3eb..a81ea4b 100755 --- a/mainwindow.py +++ b/mainwindow.py @@ -14,6 +14,7 @@ import os import sys import time import json +import pyperclip import random import base64 import shutil @@ -1880,7 +1881,10 @@ class ValueCheck(): if file == "": return try: - QtWidgets.QInputDialog.getText(window, "值", "计算得到的值", QtWidgets.QLineEdit.Normal, self.link[types](self, file)) + value = self.link[types](self, file) + if QtWidgets.QInputDialog.getText(window, "值", "下面是计算得到的值,是否要复制到剪切板?", QtWidgets.QLineEdit.Normal, value)[1]: + pyperclip.copy(value) + QtWidgets.QMessageBox.information(window, "提示", "复制成功!") except: traceback.print_exc() QtWidgets.QMessageBox.critical(window, "错误", traceback.format_exc())