新增图标

This commit is contained in:
gfdgd xi 2022-12-10 12:46:27 +08:00
parent 9fb280271b
commit 683a1a876e
7 changed files with 21 additions and 20 deletions

View File

@ -82,7 +82,7 @@ class ProgramRunStatusUpload():
def ShowWindow(): def ShowWindow():
ProgramRunStatusUpload.starList = [] ProgramRunStatusUpload.starList = []
ProgramRunStatusUpload.msgWindow = QtWidgets.QMainWindow() ProgramRunStatusUpload.msgWindow = QtWidgets.QMainWindow(ProgramRunStatusShow.msgWindow)
msgWidget = QtWidgets.QWidget() msgWidget = QtWidgets.QWidget()
msgWidgetLayout = QtWidgets.QGridLayout() msgWidgetLayout = QtWidgets.QGridLayout()
ProgramRunStatusUpload.fen = QtWidgets.QComboBox() ProgramRunStatusUpload.fen = QtWidgets.QComboBox()
@ -90,12 +90,12 @@ class ProgramRunStatusUpload():
upload = QtWidgets.QPushButton(QtCore.QCoreApplication.translate("U", "上传")) upload = QtWidgets.QPushButton(QtCore.QCoreApplication.translate("U", "上传"))
upload.clicked.connect(ProgramRunStatusUpload.Upload) upload.clicked.connect(ProgramRunStatusUpload.Upload)
# 生成星星列表 # 生成星星列表
for i in [1, 1, 1, 1, 0]: for i in [1, 1, 1, 1, 1]:
ProgramRunStatusUpload.starList.append(QtWidgets.QLabel(f"<img src='{programPath}/Icon/{['Un', ''][i]}Star.svg' width=25>")) ProgramRunStatusUpload.starList.append(QtWidgets.QLabel(f"<img src='{programPath}/Icon/{['Un', ''][i]}Star.svg' width=25>"))
ProgramRunStatusUpload.starLayout.addWidget(ProgramRunStatusUpload.starList[-1]) ProgramRunStatusUpload.starLayout.addWidget(ProgramRunStatusUpload.starList[-1])
ProgramRunStatusUpload.starLayout.addItem(QtWidgets.QSpacerItem(20, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)) ProgramRunStatusUpload.starLayout.addItem(QtWidgets.QSpacerItem(20, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum))
ProgramRunStatusUpload.fen.addItems(["0分", "1分", "2分", "3分", "4分", "5分"]) ProgramRunStatusUpload.fen.addItems(["0分", "1分", "2分", "3分", "4分", "5分"])
ProgramRunStatusUpload.fen.setCurrentIndex(4) ProgramRunStatusUpload.fen.setCurrentIndex(5)
ProgramRunStatusUpload.fen.currentIndexChanged.connect(ProgramRunStatusUpload.ChangeStar) ProgramRunStatusUpload.fen.currentIndexChanged.connect(ProgramRunStatusUpload.ChangeStar)
msgWidgetLayout.addWidget(QtWidgets.QLabel(QtCore.QCoreApplication.translate("U", "评分:")), 1, 0) msgWidgetLayout.addWidget(QtWidgets.QLabel(QtCore.QCoreApplication.translate("U", "评分:")), 1, 0)
msgWidgetLayout.addWidget(ProgramRunStatusUpload.fen, 1, 1) msgWidgetLayout.addWidget(ProgramRunStatusUpload.fen, 1, 1)
@ -109,10 +109,10 @@ class ProgramRunStatusUpload():
def Upload(): def Upload():
try: try:
QtWidgets.QMessageBox.information(None, QtCore.QCoreApplication.translate("U", "提示"), requests.get(f"http://120.25.153.144/spark-deepin-wine-runner/Install.php?Version=Fen{ProgramRunStatusUpload.fen.currentIndex()}").json()["Error"]) QtWidgets.QMessageBox.information(ProgramRunStatusUpload.msgWindow, QtCore.QCoreApplication.translate("U", "提示"), requests.get(f"http://120.25.153.144/spark-deepin-wine-runner/Install.php?Version=Fen{ProgramRunStatusUpload.fen.currentIndex()}").json()["Error"])
except: except:
traceback.print_exc() traceback.print_exc()
QtWidgets.QMessageBox.critical(None, QtCore.QCoreApplication.translate("U", "错误"), QtCore.QCoreApplication.translate("U", "数据上传失败!")) QtWidgets.QMessageBox.critical(ProgramRunStatusUpload.msgWindow, QtCore.QCoreApplication.translate("U", "错误"), QtCore.QCoreApplication.translate("U", "数据上传失败!"))
if __name__ == "__main__": if __name__ == "__main__":
programPath = os.path.split(os.path.realpath(__file__))[0] # 返回 string programPath = os.path.split(os.path.realpath(__file__))[0] # 返回 string

View File

@ -26,4 +26,4 @@ chmod 777 -R root
xhost + xhost +
# 如果参数 3 存在 # 如果参数 3 存在
chroot ${@:3} chroot . ${@:3}

View File

@ -82,7 +82,7 @@ class ProgramRunStatusUpload():
def ShowWindow(): def ShowWindow():
ProgramRunStatusUpload.starList = [] ProgramRunStatusUpload.starList = []
ProgramRunStatusUpload.msgWindow = QtWidgets.QMainWindow() ProgramRunStatusUpload.msgWindow = QtWidgets.QMainWindow(ProgramRunStatusShow.msgWindow)
msgWidget = QtWidgets.QWidget() msgWidget = QtWidgets.QWidget()
msgWidgetLayout = QtWidgets.QGridLayout() msgWidgetLayout = QtWidgets.QGridLayout()
ProgramRunStatusUpload.fen = QtWidgets.QComboBox() ProgramRunStatusUpload.fen = QtWidgets.QComboBox()
@ -90,12 +90,12 @@ class ProgramRunStatusUpload():
upload = QtWidgets.QPushButton(QtCore.QCoreApplication.translate("U", "上传")) upload = QtWidgets.QPushButton(QtCore.QCoreApplication.translate("U", "上传"))
upload.clicked.connect(ProgramRunStatusUpload.Upload) upload.clicked.connect(ProgramRunStatusUpload.Upload)
# 生成星星列表 # 生成星星列表
for i in [1, 1, 1, 1, 0]: for i in [1, 1, 1, 1, 1]:
ProgramRunStatusUpload.starList.append(QtWidgets.QLabel(f"<img src='{programPath}/Icon/{['Un', ''][i]}Star.svg' width=25>")) ProgramRunStatusUpload.starList.append(QtWidgets.QLabel(f"<img src='{programPath}/Icon/{['Un', ''][i]}Star.svg' width=25>"))
ProgramRunStatusUpload.starLayout.addWidget(ProgramRunStatusUpload.starList[-1]) ProgramRunStatusUpload.starLayout.addWidget(ProgramRunStatusUpload.starList[-1])
ProgramRunStatusUpload.starLayout.addItem(QtWidgets.QSpacerItem(20, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum)) ProgramRunStatusUpload.starLayout.addItem(QtWidgets.QSpacerItem(20, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum))
ProgramRunStatusUpload.fen.addItems(["0分", "1分", "2分", "3分", "4分", "5分"]) ProgramRunStatusUpload.fen.addItems(["0分", "1分", "2分", "3分", "4分", "5分"])
ProgramRunStatusUpload.fen.setCurrentIndex(4) ProgramRunStatusUpload.fen.setCurrentIndex(5)
ProgramRunStatusUpload.fen.currentIndexChanged.connect(ProgramRunStatusUpload.ChangeStar) ProgramRunStatusUpload.fen.currentIndexChanged.connect(ProgramRunStatusUpload.ChangeStar)
msgWidgetLayout.addWidget(QtWidgets.QLabel(QtCore.QCoreApplication.translate("U", "评分:")), 1, 0) msgWidgetLayout.addWidget(QtWidgets.QLabel(QtCore.QCoreApplication.translate("U", "评分:")), 1, 0)
msgWidgetLayout.addWidget(ProgramRunStatusUpload.fen, 1, 1) msgWidgetLayout.addWidget(ProgramRunStatusUpload.fen, 1, 1)
@ -109,10 +109,10 @@ class ProgramRunStatusUpload():
def Upload(): def Upload():
try: try:
QtWidgets.QMessageBox.information(None, QtCore.QCoreApplication.translate("U", "提示"), requests.get(f"http://120.25.153.144/spark-deepin-wine-runner/Install.php?Version=Fen{ProgramRunStatusUpload.fen.currentIndex()}").json()["Error"]) QtWidgets.QMessageBox.information(ProgramRunStatusUpload.msgWindow, QtCore.QCoreApplication.translate("U", "提示"), requests.get(f"http://120.25.153.144/spark-deepin-wine-runner/Install.php?Version=Fen{ProgramRunStatusUpload.fen.currentIndex()}").json()["Error"])
except: except:
traceback.print_exc() traceback.print_exc()
QtWidgets.QMessageBox.critical(None, QtCore.QCoreApplication.translate("U", "错误"), QtCore.QCoreApplication.translate("U", "数据上传失败!")) QtWidgets.QMessageBox.critical(ProgramRunStatusUpload.msgWindow, QtCore.QCoreApplication.translate("U", "错误"), QtCore.QCoreApplication.translate("U", "数据上传失败!"))
if __name__ == "__main__": if __name__ == "__main__":
programPath = os.path.split(os.path.realpath(__file__))[0] # 返回 string programPath = os.path.split(os.path.realpath(__file__))[0] # 返回 string

View File

@ -20,7 +20,8 @@ umount ./etc/resolv.conf
umount ./sys umount ./sys
umount ./dev/shm umount ./dev/shm
# 挂载 Wine 运行器目录 # 挂载 Wine 运行器目录
umount ./opt/apps/deepin-wine-runner/ umount ./opt
umount ./opt/apps/deepin-wine-runner
# 挂载字体 # 挂载字体
umount ./usr/share/fonts umount ./usr/share/fonts
# 挂载用户目录到 /root默认 $HOME 路径) # 挂载用户目录到 /root默认 $HOME 路径)

View File

@ -2,8 +2,8 @@
# 使用系统默认的 python3 运行 # 使用系统默认的 python3 运行
################################################################################################################# #################################################################################################################
# 作者gfdgd xi、为什么您不喜欢熊出没和阿布呢 # 作者gfdgd xi、为什么您不喜欢熊出没和阿布呢
# 版本:2.3.0 # 版本:3.0.0
# 更新时间2022年10月15 # 更新时间2022年12月10
# 感谢:感谢 wine、deepin-wine 以及星火团队,提供了 wine、deepin-wine、spark-wine-devel 给大家使用,让我能做这个程序 # 感谢:感谢 wine、deepin-wine 以及星火团队,提供了 wine、deepin-wine、spark-wine-devel 给大家使用,让我能做这个程序
# 基于 Python3 的 PyQt5 构建 # 基于 Python3 的 PyQt5 构建
################################################################################################################# #################################################################################################################
@ -2624,10 +2624,10 @@ w3 = QtWidgets.QAction(transla.transe("U", "安装自定义字体"))
w4 = QtWidgets.QAction(transla.transe("U", "删除选择的 Wine 容器")) w4 = QtWidgets.QAction(transla.transe("U", "删除选择的 Wine 容器"))
cleanBottonUOS = QtWidgets.QAction(transla.transe("U", "清理 Wine 容器(基于 Wine 适配活动脚本)")) cleanBottonUOS = QtWidgets.QAction(transla.transe("U", "清理 Wine 容器(基于 Wine 适配活动脚本)"))
wineKeyboardLnk = QtWidgets.QAction(transla.transe("U", "Wine 快捷键映射")) wineKeyboardLnk = QtWidgets.QAction(transla.transe("U", "Wine 快捷键映射"))
w5 = QtWidgets.QAction(transla.transe("U", "打包 wine 应用")) w5 = QtWidgets.QAction(QtGui.QIcon.fromTheme("deb"), transla.transe("U", "打包 wine 应用"))
w6 = QtWidgets.QAction(transla.transe("U", "使用官方 Wine 适配活动的脚本进行打包")) w6 = QtWidgets.QAction(QtGui.QIcon.fromTheme("deb"), transla.transe("U", "使用官方 Wine 适配活动的脚本进行打包"))
easyPackager = QtWidgets.QAction(transla.transe("U", "使用简易打包器进行打包(小白且无特殊需求建议使用这个)")) easyPackager = QtWidgets.QAction(QtGui.QIcon.fromTheme("deb"), transla.transe("U", "使用简易打包器进行打包(小白且无特殊需求建议使用这个)"))
getDllOnInternet = QtWidgets.QAction(transla.transe("U", "从互联网获取DLL")) getDllOnInternet = QtWidgets.QAction(QtGui.QIcon.fromTheme("1CD8_rundll32.0"), transla.transe("U", "从互联网获取DLL"))
w7 = QtWidgets.QAction(transla.transe("U", "从镜像获取DLL只支持官方安装镜像DOS内核如 Windows 95 暂不支持)")) w7 = QtWidgets.QAction(transla.transe("U", "从镜像获取DLL只支持官方安装镜像DOS内核如 Windows 95 暂不支持)"))
updateGeek = QtWidgets.QAction(transla.transe("U", "从 Geek Uninstaller 官网升级程序")) updateGeek = QtWidgets.QAction(transla.transe("U", "从 Geek Uninstaller 官网升级程序"))
deletePartIcon = QtWidgets.QAction(transla.transe("U", "快捷方式管理工具")) deletePartIcon = QtWidgets.QAction(transla.transe("U", "快捷方式管理工具"))
@ -2683,7 +2683,7 @@ settingRunV3Sh = wineOption.addMenu(transla.transe("U", "run_v3.sh 管理"))
w8 = QtWidgets.QAction(transla.transe("U", "设置 run_v3.sh 的文管为 Deepin 默认文管")) w8 = QtWidgets.QAction(transla.transe("U", "设置 run_v3.sh 的文管为 Deepin 默认文管"))
w9 = QtWidgets.QAction(transla.transe("U", "设置 run_v3.sh 的文管为 Wine 默认文管")) w9 = QtWidgets.QAction(transla.transe("U", "设置 run_v3.sh 的文管为 Wine 默认文管"))
w10 = QtWidgets.QAction(transla.transe("U", "重新安装 deepin-wine-helper")) w10 = QtWidgets.QAction(transla.transe("U", "重新安装 deepin-wine-helper"))
w11 = QtWidgets.QAction(transla.transe("U", "使用winetricks打开指定容器")) w11 = QtWidgets.QAction(QtGui.QIcon.fromTheme("winetricks"), transla.transe("U", "使用winetricks打开指定容器"))
settingRunV3Sh.addAction(w8) settingRunV3Sh.addAction(w8)
settingRunV3Sh.addAction(w9) settingRunV3Sh.addAction(w9)
settingRunV3Sh.addAction(w10) settingRunV3Sh.addAction(w10)
@ -2804,7 +2804,7 @@ netDemo.triggered.connect(lambda: RunWineProgram(f"{programPath}/Test/net.exe"))
netIEDemo.triggered.connect(lambda: RunWineProgram(f"{programPath}/Test/netandie.exe")) netIEDemo.triggered.connect(lambda: RunWineProgram(f"{programPath}/Test/netandie.exe"))
virtualMachine = menu.addMenu(transla.transe("U", "虚拟机(&V)")) virtualMachine = menu.addMenu(transla.transe("U", "虚拟机(&V)"))
v1 = QtWidgets.QAction(transla.transe("U", "使用 Virtualbox 虚拟机运行 Windows 应用")) v1 = QtWidgets.QAction(QtGui.QIcon.fromTheme("virtualbox"), transla.transe("U", "使用 Virtualbox 虚拟机运行 Windows 应用"))
virtualMachine.addAction(v1) virtualMachine.addAction(v1)
v1.triggered.connect(RunVM) v1.triggered.connect(RunVM)

Binary file not shown.