mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-30 03:20:41 +01:00
Pamhyr2: Add new logo.
This commit is contained in:
1 parent
e350b7d8f5
commit
48e010f195
5 files changed
+33
-8
No files matched your search
@@ -496,12 +496,7 @@ class ASubMainWindow(QMainWindow, ASubWindowFeatures, WindowToolKit):
|
||||
super(ASubMainWindow, self).__init__(parent=parent)
|
||||
if ui is not None:
|
||||
self.ui = loadUi(
|
||||
os.path.abspath(
|
||||
os.path.join(
|
||||
os.path.dirname(__file__),
|
||||
"..", "ui", f"{ui}.ui"
|
||||
)
|
||||
),
|
||||
os.path.join(self._get_ui_directory(), f"{ui}.ui"),
|
||||
self
|
||||
)
|
||||
|
||||
@@ -510,6 +505,14 @@ class ASubMainWindow(QMainWindow, ASubWindowFeatures, WindowToolKit):
|
||||
if self.parent is not None:
|
||||
self.parent.sub_win_add(name, self)
|
||||
|
||||
def _get_ui_directory(self):
|
||||
return os.path.abspath(
|
||||
os.path.join(
|
||||
os.path.dirname(__file__),
|
||||
"..", "ui"
|
||||
)
|
||||
)
|
||||
|
||||
def closeEvent(self, event):
|
||||
if self.parent is not None:
|
||||
self.parent.sub_win_del(self.hash())
|
||||
|
||||
Reference in new issue
Block a user