mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-30 03:20:41 +01:00
refactoring: Add PamhyrWindow and PamhyrDialog (WIP).
This commit is contained in:
1 parent
9c7f1f7ba9
commit
fa32e42933
11 files changed
+408
-194
No files matched your search
@@ -19,14 +19,17 @@
|
||||
import os
|
||||
import logging
|
||||
|
||||
from View.ASubWindow import ASubWindow
|
||||
from View.Tools.PamhyrWindow import PamhyrDialog
|
||||
|
||||
from PyQt5.QtCore import QCoreApplication
|
||||
|
||||
_translate = QCoreApplication.translate
|
||||
logger = logging.getLogger()
|
||||
|
||||
class AboutWindow(ASubWindow):
|
||||
class AboutWindow(PamhyrDialog):
|
||||
_pamhyr_ui = "about"
|
||||
_pamhyr_name = "About"
|
||||
|
||||
def _path_file(self, filename):
|
||||
return os.path.abspath(
|
||||
os.path.join(
|
||||
@@ -35,10 +38,14 @@ class AboutWindow(ASubWindow):
|
||||
)
|
||||
)
|
||||
|
||||
|
||||
def __init__(self, title="About", parent=None):
|
||||
super(AboutWindow, self).__init__(name=title, ui="about", parent=parent)
|
||||
self.ui.setWindowTitle(title)
|
||||
def __init__(self, study = None, config = None, parent=None):
|
||||
super(AboutWindow, self).__init__(
|
||||
title = _translate("About", "About"),
|
||||
study = study,
|
||||
config = config,
|
||||
options = [],
|
||||
parent = parent
|
||||
)
|
||||
|
||||
# Version
|
||||
with open(self._path_file("VERSION"), "r") as f:
|
||||
|
||||
Reference in new issue
Block a user