pyloid 0.23.2__tar.gz → 0.23.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pyloid-0.23.2 → pyloid-0.23.3}/PKG-INFO +1 -1
- {pyloid-0.23.2 → pyloid-0.23.3}/pyproject.toml +1 -1
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/browser_window.py +4 -4
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/js_api/base.py +7 -1
- {pyloid-0.23.2 → pyloid-0.23.3}/LICENSE +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/README.md +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/__init__.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/api.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/autostart.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/custom/titlebar.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/filewatcher.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/js_api/event_api.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/js_api/window_api.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/monitor.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/pyloid.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/rpc.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/serve.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/store.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/thread_pool.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/timer.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/tray.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/url_interceptor.py +0 -0
- {pyloid-0.23.2 → pyloid-0.23.3}/src/pyloid/utils.py +0 -0
@@ -43,7 +43,7 @@ from PySide6.QtWebEngineCore import (
|
|
43
43
|
QWebEngineDesktopMediaRequest,
|
44
44
|
)
|
45
45
|
|
46
|
-
from .url_interceptor import CustomUrlInterceptor
|
46
|
+
# from .url_interceptor import CustomUrlInterceptor
|
47
47
|
from .rpc import PyloidRPC
|
48
48
|
|
49
49
|
if TYPE_CHECKING:
|
@@ -323,8 +323,8 @@ class _BrowserWindow:
|
|
323
323
|
self.rpc_url = None
|
324
324
|
|
325
325
|
# interceptor ( all url request )
|
326
|
-
self.interceptor = CustomUrlInterceptor(rpc_url=self.rpc_url)
|
327
|
-
self.web_view.page().setUrlRequestInterceptor(self.interceptor)
|
326
|
+
# self.interceptor = CustomUrlInterceptor(rpc_url=self.rpc_url)
|
327
|
+
# self.web_view.page().setUrlRequestInterceptor(self.interceptor)
|
328
328
|
|
329
329
|
self._window.closeEvent = self.closeEvent # Override closeEvent method
|
330
330
|
###########################################################################################
|
@@ -338,7 +338,7 @@ class _BrowserWindow:
|
|
338
338
|
self.context_menu = context_menu
|
339
339
|
self.dev_tools = dev_tools
|
340
340
|
|
341
|
-
self.js_apis = [BaseAPI(self.id, self.app.data, self.app)]
|
341
|
+
self.js_apis = [BaseAPI(self.id, self.app.data, self.app, self.rpc_url)]
|
342
342
|
|
343
343
|
# for js_api in js_apis:
|
344
344
|
# self.js_apis.append(js_api)
|
@@ -10,11 +10,12 @@ if TYPE_CHECKING:
|
|
10
10
|
|
11
11
|
|
12
12
|
class BaseAPI(PyloidAPI):
|
13
|
-
def __init__(self, window_id: str, data: dict, app: "Pyloid"):
|
13
|
+
def __init__(self, window_id: str, data: dict, app: "Pyloid", rpc_url: Optional[str] = None):
|
14
14
|
super().__init__()
|
15
15
|
self.window_id: str = window_id
|
16
16
|
self.data: dict = data
|
17
17
|
self.app: "Pyloid" = app
|
18
|
+
self.rpc_url: Optional[str] = rpc_url
|
18
19
|
|
19
20
|
@Bridge(result=dict)
|
20
21
|
def getData(self):
|
@@ -252,4 +253,9 @@ class BaseAPI(PyloidAPI):
|
|
252
253
|
"""Returns the production path of the application."""
|
253
254
|
return get_production_path(path)
|
254
255
|
|
256
|
+
@Bridge(result=str)
|
257
|
+
def getRpcUrl(self):
|
258
|
+
"""Returns the RPC URL of the application."""
|
259
|
+
return self.rpc_url
|
260
|
+
|
255
261
|
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|