Split main.py to separate packages and classes
This commit is contained in:
parent
a4894d612a
commit
64c9a96491
6 changed files with 29 additions and 11 deletions
18
app/LauncherApplication.py
Normal file
18
app/LauncherApplication.py
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
import webview
|
||||
|
||||
from app.Version import Version
|
||||
from app.webview_api import WebviewApi
|
||||
|
||||
|
||||
class LauncherApplication:
|
||||
def __init__(self, app_root):
|
||||
self.webviewApi = WebviewApi()
|
||||
self.window = webview.create_window(Version.get_full_name(), app_root + '/assets/index.html', js_api=self.webviewApi, min_size=(600,400))
|
||||
|
||||
def start(self):
|
||||
webview.start(debug=True)
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
app = LauncherApplication('..')
|
||||
app.start()
|
||||
Loading…
Add table
Add a link
Reference in a new issue