forked from tonquer/picacg-qt
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
42 changed files
with
779 additions
and
69 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,14 @@ | |
# tonquer<[email protected]> | ||
# https://github.com/tonquer/picacg-qt | ||
###################################################################################### | ||
# Version: v1.4.0 | ||
# 2022/9/25 | ||
# 1) 新增一个反代分流(其他分流不可用时解锁,防止滥用) | ||
# 2) 设置中新增关闭时可最小化到托盘 | ||
# 3) 下载界面,有更新章节时显示NEW | ||
# 4) 收藏界面,有更新章节时显示NEW | ||
# 5) 修复部分漫画无法显示所以章节 | ||
|
||
# Version: v1.3.9 | ||
# 2022/8/14 | ||
# 1) 漫画详情新增大家都在看 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
cd src | ||
pyinstaller --clean --onedir --name PicACG \ | ||
--hidden-import waifu2x_vulkan --hidden-import PySide6 --hidden-import requests \ | ||
--hidden-import urllib3 --hidden-import websocket-client --hidden-import pillow \ | ||
--hidden-import config | ||
--hidden-import component | ||
--hidden-import server | ||
--hidden-import task | ||
--hidden-import tools | ||
--hidden-import view | ||
--strip --windowed -i Icon.icns \ | ||
start.py |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
from PySide6.QtWidgets import QApplication | ||
|
||
from component.dialog.base_mask_dialog import BaseMaskDialog | ||
from config.setting import Setting | ||
from interface.ui_exit import Ui_Exit | ||
from qt_owner import QtOwner | ||
|
||
|
||
class ShowCloseDialog(BaseMaskDialog, Ui_Exit): | ||
|
||
def __init__(self, parent=None): | ||
BaseMaskDialog.__init__(self, parent) | ||
Ui_Exit.__init__(self) | ||
self.widget.adjustSize() | ||
self.setupUi(self.widget) | ||
self.buttonGroup.setId(self.radioButton1, 0) | ||
self.buttonGroup.setId(self.radioButton2, 1) | ||
self.button.clicked.connect(self.Click) | ||
self.checkBox.clicked.connect(self.SwitchCheckBox) | ||
|
||
def SwitchCheckBox(self, check): | ||
Setting.IsNotShowCloseTip.SetValue(int(self.checkBox.isChecked())) | ||
|
||
def Click(self): | ||
if self.radioButton1.isChecked(): | ||
Setting.ShowCloseType.SetValue(0) | ||
self.close() | ||
QtOwner().closeType = 2 | ||
QApplication.quit() | ||
else: | ||
QtOwner().owner.myTrayIcon.show() | ||
Setting.ShowCloseType.SetValue(1) | ||
self.close() | ||
QtOwner().owner.hide() | ||
return | ||
|
||
def LoadSetting(self): | ||
self.checkBox.setChecked(bool(Setting.IsNotShowCloseTip.value)) | ||
button = getattr(self, "radioButton{}".format(int(Setting.ShowCloseType.value+1))) | ||
button.setChecked(True) | ||
return |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
from PySide6.QtGui import QIcon, QAction | ||
from PySide6.QtWidgets import QSystemTrayIcon, QMenu, QApplication | ||
|
||
from qt_owner import QtOwner | ||
from tools.str import Str | ||
|
||
|
||
class MySystemTrayIcon(QSystemTrayIcon): | ||
def __init__(self, parent=None): | ||
super().__init__(parent) | ||
self.count = 0 | ||
self.setIcon(QIcon(":/png/icon/logo_round.png")) | ||
self.setToolTip("PicACG") | ||
self.menu = QMenu() | ||
mainUi = QAction(Str.GetStr(Str.MainUi), self) | ||
mainUi.triggered.connect(self.ShowMainUi) | ||
|
||
showMin = QAction(Str.GetStr(Str.ShowMin), self) | ||
showMin.triggered.connect(self.ShowMin) | ||
|
||
quit = QAction(Str.GetStr(Str.Exit), self) | ||
quit.triggered.connect(self.Close) | ||
|
||
self.menu.addAction(mainUi) | ||
self.menu.addAction(showMin) | ||
self.menu.addAction(quit) | ||
self.setContextMenu(self.menu) | ||
self.activated.connect(self.OnActive) | ||
|
||
def ShowMainUi(self): | ||
QtOwner().owner.show() | ||
pass | ||
|
||
def ShowMin(self): | ||
QtOwner().owner.hide() | ||
pass | ||
|
||
def Close(self): | ||
QtOwner().closeType = 3 | ||
QtOwner().owner.close() | ||
|
||
def OnActive(self, reason): | ||
if reason == QSystemTrayIcon.Trigger: | ||
return | ||
elif reason == QSystemTrayIcon.DoubleClick: | ||
self.ShowMainUi() | ||
return | ||
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.