def __init__(self, html, app, hub, window_size, debug=False):
QMainWindow.__init__(self)
self.app = app
self.hub = hub
self.debug = debug
self.html = html
self.url = "file:///" \
+ os.path.join(self.app.property("ResPath"), "www/").replace('\\', '/')
self.is_first_load = True
self.view = web_core.QWebView(self)
if not self.debug:
self.view.setContextMenuPolicy(qt_core.Qt.NoContextMenu)
self.view.setCursor(qt_core.Qt.ArrowCursor)
self.view.setZoomFactor(1)
self.setWindowTitle(APP_NAME)
self.icon = self._getQIcon('sumokoin_icon_64.png')
self.setWindowIcon(self.icon)
self.setCentralWidget(self.view)
self.setFixedSize(window_size)
self.center()
if sys.platform == 'win32':
psutil.Process().nice(psutil.HIGH_PRIORITY_CLASS)
评论列表
文章目录