forked from NinjaCheetah/NUSGet
Slightly increase window size, improve about dialog
This commit is contained in:
parent
249ba861ff
commit
917b9f665a
21
NUSGet.py
21
NUSGet.py
@ -96,7 +96,7 @@ class MainWindow(QMainWindow, Ui_MainWindow):
|
|||||||
self.ui.auto_update_checkbox.toggled.connect(
|
self.ui.auto_update_checkbox.toggled.connect(
|
||||||
lambda: update_setting(config_data, "auto_update", self.ui.auto_update_checkbox.isChecked()))
|
lambda: update_setting(config_data, "auto_update", self.ui.auto_update_checkbox.isChecked()))
|
||||||
# Load custom output directory if one is saved and it is valid. Only enable the checkbox to actually use the
|
# Load custom output directory if one is saved and it is valid. Only enable the checkbox to actually use the
|
||||||
# custom dir if use_out_path is set to true.
|
# custom dir if "use_out_path" is set to true.
|
||||||
try:
|
try:
|
||||||
out_dir = pathlib.Path(config_data["out_path"])
|
out_dir = pathlib.Path(config_data["out_path"])
|
||||||
if out_dir.exists() and out_dir.is_dir():
|
if out_dir.exists() and out_dir.is_dir():
|
||||||
@ -111,17 +111,11 @@ class MainWindow(QMainWindow, Ui_MainWindow):
|
|||||||
self.ui.tid_entry.textChanged.connect(self.tid_updated)
|
self.ui.tid_entry.textChanged.connect(self.tid_updated)
|
||||||
self.ui.custom_out_dir_entry.textChanged.connect(self.custom_output_dir_changed)
|
self.ui.custom_out_dir_entry.textChanged.connect(self.custom_output_dir_changed)
|
||||||
# Basic intro text set to automatically show when the app loads. This may be changed in the future.
|
# Basic intro text set to automatically show when the app loads. This may be changed in the future.
|
||||||
libwiipy_version = "v" + version("libWiiPy")
|
self.log_text = app.translate("MainWindow", "Select a title from the list on the left, or enter a "
|
||||||
libtwlpy_version = "v" + version("libTWLPy")
|
"Title ID to begin.\n\nTitles marked with a checkmark are free and have a ticket "
|
||||||
self.log_text = (app.translate("MainWindow", "NUSGet v{nusget_version}\nDeveloped by NinjaCheetah\nPowered by libWiiPy "
|
"available, and can be decrypted and/or packed into a WAD or TAD. Titles with an X do not"
|
||||||
"{libwiipy_version}\nDSi support provided by libTWLPy {libtwlpy_version}\n\n"
|
" have a ticket, and only their encrypted contents can be saved.\n\nBy default, titles "
|
||||||
"Select a title from the list on the left, or enter a Title ID to begin.\n\n"
|
"will be downloaded to a folder named \"NUSGet Downloads\" inside your downloads folder.")
|
||||||
"Titles marked with a checkmark are free and have a ticket available, and can"
|
|
||||||
" be decrypted and/or packed into a WAD or TAD. Titles with an X do not have "
|
|
||||||
"a ticket, and only their encrypted contents can be saved.\n\nBy default, titles will be "
|
|
||||||
"downloaded to a folder named \"NUSGet Downloads\" inside your downloads folder.")
|
|
||||||
.format(nusget_version=nusget_version, libwiipy_version=libwiipy_version,
|
|
||||||
libtwlpy_version=libtwlpy_version))
|
|
||||||
self.ui.log_text_browser.setText(self.log_text)
|
self.ui.log_text_browser.setText(self.log_text)
|
||||||
# Add console entries to dropdown and attach on change signal.
|
# Add console entries to dropdown and attach on change signal.
|
||||||
self.ui.console_select_dropdown.addItem("Wii")
|
self.ui.console_select_dropdown.addItem("Wii")
|
||||||
@ -570,8 +564,7 @@ class MainWindow(QMainWindow, Ui_MainWindow):
|
|||||||
save_config(config_data)
|
save_config(config_data)
|
||||||
|
|
||||||
def about_nusget(self):
|
def about_nusget(self):
|
||||||
version_str = app.translate("MainWindow", "Version {nusget_version}".format(nusget_version=nusget_version))
|
about_box = AboutNUSGet([nusget_version, version("libWiiPy"), version("libTWLPy")])
|
||||||
about_box = AboutNUSGet(version_str)
|
|
||||||
about_box.exec()
|
about_box.exec()
|
||||||
|
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@ from PySide6.QtWidgets import QDialog, QLabel, QVBoxLayout, QPushButton
|
|||||||
from PySide6.QtGui import QIcon
|
from PySide6.QtGui import QIcon
|
||||||
|
|
||||||
class AboutNUSGet(QDialog):
|
class AboutNUSGet(QDialog):
|
||||||
def __init__(self, version_str):
|
def __init__(self, versions):
|
||||||
super().__init__()
|
super().__init__()
|
||||||
self.setWindowTitle(self.tr("About NUSGet"))
|
self.setWindowTitle(self.tr("About NUSGet"))
|
||||||
self.setFixedWidth(450)
|
self.setFixedWidth(450)
|
||||||
@ -83,11 +83,17 @@ class AboutNUSGet(QDialog):
|
|||||||
title_label.setProperty("class", "title")
|
title_label.setProperty("class", "title")
|
||||||
title_label.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
title_label.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
# Version
|
# NUSGet Version
|
||||||
version_label = QLabel(self.tr("{version_str}".format(version_str=version_str)))
|
version_label = QLabel(self.tr("Version {nusget_version}".format(nusget_version=versions[0])))
|
||||||
version_label.setProperty("class", "version")
|
version_label.setProperty("class", "version")
|
||||||
version_label.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
version_label.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
|
# Library Versions
|
||||||
|
libraries_label = QLabel(self.tr("Using libWiiPy {libwiipy_version} & libTWLPy {libtwlpy_version}"
|
||||||
|
.format(libwiipy_version=versions[1], libtwlpy_version=versions[2])))
|
||||||
|
libraries_label.setProperty("class", "version")
|
||||||
|
libraries_label.setAlignment(Qt.AlignmentFlag.AlignCenter)
|
||||||
|
|
||||||
# Copyright
|
# Copyright
|
||||||
copyright_label = QLabel(self.tr("© 2024-2025 NinjaCheetah & Contributors"))
|
copyright_label = QLabel(self.tr("© 2024-2025 NinjaCheetah & Contributors"))
|
||||||
copyright_label.setProperty("class", "copyright")
|
copyright_label.setProperty("class", "copyright")
|
||||||
@ -97,6 +103,7 @@ class AboutNUSGet(QDialog):
|
|||||||
self.layout.addWidget(logo_label)
|
self.layout.addWidget(logo_label)
|
||||||
self.layout.addWidget(title_label)
|
self.layout.addWidget(title_label)
|
||||||
self.layout.addWidget(version_label)
|
self.layout.addWidget(version_label)
|
||||||
|
self.layout.addWidget(libraries_label)
|
||||||
self.layout.addWidget(copyright_label)
|
self.layout.addWidget(copyright_label)
|
||||||
self.layout.addSpacing(15)
|
self.layout.addSpacing(15)
|
||||||
|
|
||||||
|
@ -28,9 +28,9 @@ class Ui_MainWindow(object):
|
|||||||
def setupUi(self, MainWindow):
|
def setupUi(self, MainWindow):
|
||||||
if not MainWindow.objectName():
|
if not MainWindow.objectName():
|
||||||
MainWindow.setObjectName(u"MainWindow")
|
MainWindow.setObjectName(u"MainWindow")
|
||||||
MainWindow.resize(1010, 625)
|
MainWindow.resize(1010, 675)
|
||||||
MainWindow.setMinimumSize(QSize(1010, 625))
|
MainWindow.setMinimumSize(QSize(1010, 675))
|
||||||
MainWindow.setMaximumSize(QSize(1010, 625))
|
MainWindow.setMaximumSize(QSize(1010, 675))
|
||||||
self.actionAbout = QAction(MainWindow)
|
self.actionAbout = QAction(MainWindow)
|
||||||
self.actionAbout.setObjectName(u"actionAbout")
|
self.actionAbout.setObjectName(u"actionAbout")
|
||||||
icon = QIcon(QIcon.fromTheme(QIcon.ThemeIcon.HelpAbout))
|
icon = QIcon(QIcon.fromTheme(QIcon.ThemeIcon.HelpAbout))
|
||||||
@ -310,7 +310,7 @@ class Ui_MainWindow(object):
|
|||||||
MainWindow.setCentralWidget(self.centralwidget)
|
MainWindow.setCentralWidget(self.centralwidget)
|
||||||
self.menubar = QMenuBar(MainWindow)
|
self.menubar = QMenuBar(MainWindow)
|
||||||
self.menubar.setObjectName(u"menubar")
|
self.menubar.setObjectName(u"menubar")
|
||||||
self.menubar.setGeometry(QRect(0, 0, 1010, 21))
|
self.menubar.setGeometry(QRect(0, 0, 1010, 30))
|
||||||
self.menuHelp = QMenu(self.menubar)
|
self.menuHelp = QMenu(self.menubar)
|
||||||
self.menuHelp.setObjectName(u"menuHelp")
|
self.menuHelp.setObjectName(u"menuHelp")
|
||||||
MainWindow.setMenuBar(self.menubar)
|
MainWindow.setMenuBar(self.menubar)
|
||||||
@ -359,7 +359,7 @@ class Ui_MainWindow(object):
|
|||||||
"hr { height: 1px; border-width: 0; }\n"
|
"hr { height: 1px; border-width: 0; }\n"
|
||||||
"li.unchecked::marker { content: \"\\2610\"; }\n"
|
"li.unchecked::marker { content: \"\\2610\"; }\n"
|
||||||
"li.checked::marker { content: \"\\2612\"; }\n"
|
"li.checked::marker { content: \"\\2612\"; }\n"
|
||||||
"</style></head><body style=\" font-family:'.AppleSystemUIFont'; font-size:13pt; font-weight:400; font-style:normal;\">\n"
|
"</style></head><body style=\" font-family:'Noto Sans'; font-size:10pt; font-weight:400; font-style:normal;\">\n"
|
||||||
"<p style=\"-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans Serif'; font-size:9pt;\"><br /></p></body></html>", None))
|
"<p style=\"-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans Serif'; font-size:9pt;\"><br /></p></body></html>", None))
|
||||||
self.menuHelp.setTitle(QCoreApplication.translate("MainWindow", u"Help", None))
|
self.menuHelp.setTitle(QCoreApplication.translate("MainWindow", u"Help", None))
|
||||||
# retranslateUi
|
# retranslateUi
|
||||||
|
@ -7,19 +7,19 @@
|
|||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>1010</width>
|
<width>1010</width>
|
||||||
<height>625</height>
|
<height>675</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="minimumSize">
|
<property name="minimumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>1010</width>
|
<width>1010</width>
|
||||||
<height>625</height>
|
<height>675</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="maximumSize">
|
<property name="maximumSize">
|
||||||
<size>
|
<size>
|
||||||
<width>1010</width>
|
<width>1010</width>
|
||||||
<height>625</height>
|
<height>675</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
@ -425,7 +425,7 @@ p, li { white-space: pre-wrap; }
|
|||||||
hr { height: 1px; border-width: 0; }
|
hr { height: 1px; border-width: 0; }
|
||||||
li.unchecked::marker { content: "\2610"; }
|
li.unchecked::marker { content: "\2610"; }
|
||||||
li.checked::marker { content: "\2612"; }
|
li.checked::marker { content: "\2612"; }
|
||||||
</style></head><body style=" font-family:'.AppleSystemUIFont'; font-size:13pt; font-weight:400; font-style:normal;">
|
</style></head><body style=" font-family:'Noto Sans'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans Serif'; font-size:9pt;"><br /></p></body></html></string>
|
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Sans Serif'; font-size:9pt;"><br /></p></body></html></string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
@ -440,7 +440,7 @@ li.checked::marker { content: "\2612"; }
|
|||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>1010</width>
|
<width>1010</width>
|
||||||
<height>21</height>
|
<height>30</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QMenu" name="menuHelp">
|
<widget class="QMenu" name="menuHelp">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user