diff --git a/NUSGet.py b/NUSGet.py index 320f5ed..3b5b795 100644 --- a/NUSGet.py +++ b/NUSGet.py @@ -129,6 +129,10 @@ class MainWindow(QMainWindow, Ui_MainWindow): self.ui.menuHelp.setWindowFlags(self.ui.menuHelp.windowFlags() | Qt.FramelessWindowHint) self.ui.menuHelp.setWindowFlags(self.ui.menuHelp.windowFlags() | Qt.NoDropShadowWindowHint) self.ui.menuHelp.setAttribute(Qt.WA_TranslucentBackground) + # Load the custom information icon. + icon = QIcon(os.path.join(os.path.dirname(__file__), "resources", "information.svg")) + self.ui.actionAbout.setIcon(icon) + self.ui.actionAbout_Qt.setIcon(icon) # Title tree loading code. Now powered by Models:tm: wii_model = NUSGetTreeModel(wii_database, root_name="Wii Titles") vwii_model = NUSGetTreeModel(vwii_database, root_name="vWii Titles") @@ -645,7 +649,7 @@ if __name__ == "__main__": # NUSGet look nice and pretty. app.setStyle("fusion") stylesheet = open(os.path.join(os.path.dirname(__file__), "resources", "style.qss")).read() - image_path_prefix = pathlib.Path(os.path.join(os.path.dirname(__file__), "resources")).resolve().as_posix() + image_path_prefix = os.path.join(os.path.dirname(__file__), "resources") stylesheet = stylesheet.replace("{IMAGE_PREFIX}", image_path_prefix) app.setStyleSheet(stylesheet) diff --git a/qt/py/ui_AboutDialog.py b/qt/py/ui_AboutDialog.py index e6f66b7..e4cb010 100644 --- a/qt/py/ui_AboutDialog.py +++ b/qt/py/ui_AboutDialog.py @@ -73,7 +73,7 @@ class AboutNUSGet(QDialog): # Logo logo_label = QLabel() - icon = QIcon(os.path.join(pathlib.Path(os.path.dirname(__file__)).resolve().parent.parent, "resources", "icon.png")) + icon = QIcon(str(pathlib.Path(os.path.dirname(__file__)).parents[1].joinpath("resources", "icon.png"))) logo_pixmap = icon.pixmap(96, 96) logo_label.setPixmap(logo_pixmap) logo_label.setAlignment(Qt.AlignmentFlag.AlignCenter) diff --git a/resources/information.svg b/resources/information.svg new file mode 100644 index 0000000..3a6f437 --- /dev/null +++ b/resources/information.svg @@ -0,0 +1,46 @@ + + + + + + + + + +