pyloid 0.24.7__py3-none-any.whl → 0.24.8__py3-none-any.whl
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/browser_window.py +23 -20
- pyloid/store.py +2 -7
- {pyloid-0.24.7.dist-info → pyloid-0.24.8.dist-info}/LICENSE +1 -1
- {pyloid-0.24.7.dist-info → pyloid-0.24.8.dist-info}/METADATA +2 -2
- {pyloid-0.24.7.dist-info → pyloid-0.24.8.dist-info}/RECORD +6 -6
- {pyloid-0.24.7.dist-info → pyloid-0.24.8.dist-info}/WHEEL +0 -0
pyloid/browser_window.py
CHANGED
@@ -40,7 +40,7 @@ from PySide6.QtWidgets import QSplashScreen, QLabel
|
|
40
40
|
from typing import TYPE_CHECKING, Any
|
41
41
|
from PySide6.QtWebEngineCore import (
|
42
42
|
QWebEngineSettings,
|
43
|
-
|
43
|
+
QWebEngineDesktopMediaRequest,
|
44
44
|
)
|
45
45
|
import threading
|
46
46
|
|
@@ -55,7 +55,7 @@ class CustomWebPage(QWebEnginePage):
|
|
55
55
|
def __init__(self, profile=None):
|
56
56
|
super().__init__(profile)
|
57
57
|
self.featurePermissionRequested.connect(self._handlePermissionRequest)
|
58
|
-
|
58
|
+
self.desktopMediaRequested.connect(self._handleDesktopMediaRequest)
|
59
59
|
self._permission_handlers = {}
|
60
60
|
self._desktop_media_handler = None
|
61
61
|
self._url_handlers = {} # URL 핸들러 저장을 위한 딕셔너리 추가
|
@@ -78,27 +78,27 @@ class CustomWebPage(QWebEnginePage):
|
|
78
78
|
"""Register a handler for a specific permission"""
|
79
79
|
self._permission_handlers[feature] = handler
|
80
80
|
|
81
|
-
|
82
|
-
|
83
|
-
|
81
|
+
def _handleDesktopMediaRequest(self, request: QWebEngineDesktopMediaRequest):
|
82
|
+
return
|
83
|
+
print("Desktop media request received:", request)
|
84
84
|
|
85
|
-
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
85
|
+
# 사용 가능한 화면 목록 확인
|
86
|
+
screens_model = request.screensModel()
|
87
|
+
print("\n=== Available Screens ===")
|
88
|
+
for i in range(screens_model.rowCount()):
|
89
|
+
screen_index = screens_model.index(i)
|
90
|
+
screen_name = screens_model.data(screen_index)
|
91
|
+
print(f"Screen {i}: {screen_name}")
|
92
92
|
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
93
|
+
# 사용 가능한 창 목록 확인
|
94
|
+
windows_model = request.windowsModel()
|
95
|
+
print("\n=== Available Windows ===")
|
96
|
+
for i in range(windows_model.rowCount()):
|
97
|
+
window_index = windows_model.index(i)
|
98
|
+
window_name = windows_model.data(window_index)
|
99
|
+
print(f"Window {i}: {window_name}")
|
100
100
|
|
101
|
-
|
101
|
+
request.selectWindow(windows_model.index(3))
|
102
102
|
|
103
103
|
# # interceptor ( navigation request )
|
104
104
|
# def acceptNavigationRequest(self, url, navigation_type, is_main_frame):
|
@@ -490,6 +490,9 @@ class _BrowserWindow:
|
|
490
490
|
self.web_view.settings().setAttribute(
|
491
491
|
QWebEngineSettings.WebAttribute.WebRTCPublicInterfacesOnly, False
|
492
492
|
)
|
493
|
+
self.web_view.settings().setAttribute(
|
494
|
+
QWebEngineSettings.WebAttribute.WebGLEnabled, True
|
495
|
+
)
|
493
496
|
|
494
497
|
# Set icon
|
495
498
|
if self.app.icon:
|
pyloid/store.py
CHANGED
@@ -20,7 +20,7 @@ class Store:
|
|
20
20
|
os.makedirs(os.path.dirname(path), exist_ok=True)
|
21
21
|
self.db = PickleDB(path)
|
22
22
|
|
23
|
-
def get(self, key: str
|
23
|
+
def get(self, key: str) -> Any:
|
24
24
|
"""
|
25
25
|
Retrieve the value associated with the specified key.
|
26
26
|
|
@@ -28,8 +28,6 @@ class Store:
|
|
28
28
|
----------
|
29
29
|
key: str
|
30
30
|
The key to look up in the database
|
31
|
-
default: Any
|
32
|
-
The value to return if the value does not exist in the database
|
33
31
|
|
34
32
|
Returns
|
35
33
|
-------
|
@@ -46,11 +44,8 @@ class Store:
|
|
46
44
|
{'name': 'John Doe', 'age': 30}
|
47
45
|
>>> print(store.get("non_existent_key"))
|
48
46
|
None
|
49
|
-
>>> print(store.get("non_existent_key", "default_value"))
|
50
|
-
'default_value'
|
51
47
|
"""
|
52
|
-
|
53
|
-
return stored_value if stored_value is not None else default
|
48
|
+
return self.db.get(key)
|
54
49
|
|
55
50
|
def set(self, key: str, value: Any) -> bool:
|
56
51
|
"""
|
@@ -198,4 +198,4 @@ Apache License
|
|
198
198
|
distributed under the License is distributed on an "AS IS" BASIS,
|
199
199
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
200
200
|
See the License for the specific language governing permissions and
|
201
|
-
limitations under the License.
|
201
|
+
limitations under the License.
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.3
|
2
2
|
Name: pyloid
|
3
|
-
Version: 0.24.
|
3
|
+
Version: 0.24.8
|
4
4
|
Summary:
|
5
5
|
Author: aesthetics-of-record
|
6
6
|
Author-email: 111675679+aesthetics-of-record@users.noreply.github.com
|
@@ -14,7 +14,7 @@ Classifier: Programming Language :: Python :: 3.13
|
|
14
14
|
Requires-Dist: aiohttp-cors (>=0.8.1,<0.9.0)
|
15
15
|
Requires-Dist: pickledb (>=1.3.2,<2.0.0)
|
16
16
|
Requires-Dist: platformdirs (>=4.3.7,<5.0.0)
|
17
|
-
Requires-Dist: pyside6 (==6.
|
17
|
+
Requires-Dist: pyside6 (==6.9.1)
|
18
18
|
Description-Content-Type: text/markdown
|
19
19
|
|
20
20
|
<h1 style="text-align: center; font-size: 200px; font-weight: 500;">
|
@@ -1,7 +1,7 @@
|
|
1
1
|
pyloid/__init__.py,sha256=YKwMCSOds1QVi9N7EGfY0Z7BEjJn8j6HGqRblZlZClA,235
|
2
2
|
pyloid/api.py,sha256=A61Kmddh8BlpT3LfA6NbPQNzFmD95vQ4WKX53oKsGYU,2419
|
3
3
|
pyloid/autostart.py,sha256=K7DQYl4LHItvPp0bt1V9WwaaZmVSTeGvadkcwG-KKrI,3899
|
4
|
-
pyloid/browser_window.py,sha256=
|
4
|
+
pyloid/browser_window.py,sha256=xy_AOZiqY5kffMXgkeDa5a1u1VSPv860_W9xg3wyWEI,104349
|
5
5
|
pyloid/custom/titlebar.py,sha256=itzK9pJbZMQ7BKca9kdbuHMffurrw15UijR6OU03Xsk,3894
|
6
6
|
pyloid/filewatcher.py,sha256=3M5zWVUf1OhlkWJcDFC8ZA9agO4Q-U8WdgGpy6kaVz0,4601
|
7
7
|
pyloid/js_api/base.py,sha256=Z3ID-4AJ0eHusmljRltlSaK4m2RKvRNfmqX76NLF77o,8585
|
@@ -11,13 +11,13 @@ pyloid/monitor.py,sha256=1mXvHm5deohnNlTLcRx4sT4x-stnOIb0dUQnnxN50Uo,28295
|
|
11
11
|
pyloid/pyloid.py,sha256=DSHpMRDW4WvZgAAo2nJMesMJuOkNTVEEsDhCFIvjB5w,84509
|
12
12
|
pyloid/rpc.py,sha256=OnF1sRGok9OJ-Q5519eQARD4oZTohyPhsPAT2Mg4_Gg,20377
|
13
13
|
pyloid/serve.py,sha256=wJIBqiLr1-8FvBdV3yybeBtVXsu94FfWYKjHL0eQ68s,1444
|
14
|
-
pyloid/store.py,sha256=
|
14
|
+
pyloid/store.py,sha256=teoa-HYzwm93Rivcw3AhKw6rAmQqQ_kmF6XYSkC3G_I,4541
|
15
15
|
pyloid/thread_pool.py,sha256=fKOBb8jMfZn_7crA_fJCno8dObBRZE31EIWaNQ759aw,14616
|
16
16
|
pyloid/timer.py,sha256=RqMsChFUd93cxMVgkHWiIKrci0QDTBgJSTULnAtYT8M,8712
|
17
17
|
pyloid/tray.py,sha256=D12opVEc2wc2T4tK9epaN1oOdeziScsIVNM2uCN7C-A,1710
|
18
18
|
pyloid/url_interceptor.py,sha256=AFjPANDELc9-E-1TnVvkNVc-JZBJYf0677dWQ8LDaqw,726
|
19
19
|
pyloid/utils.py,sha256=J6owgVE1YDOEfcOPmoP9m9Q6nbYDyNEo9uqPsJs5p5g,6644
|
20
|
-
pyloid-0.24.
|
21
|
-
pyloid-0.24.
|
22
|
-
pyloid-0.24.
|
23
|
-
pyloid-0.24.
|
20
|
+
pyloid-0.24.8.dist-info/LICENSE,sha256=MTYF-6xpRekyTUglRweWtbfbwBL1I_3Bgfbm_SNOuI8,11525
|
21
|
+
pyloid-0.24.8.dist-info/METADATA,sha256=IGiJsO7-sG69DSi9Rw_Hn4Ttuf-T2nquIacuZBWSI5Q,2264
|
22
|
+
pyloid-0.24.8.dist-info/WHEEL,sha256=IYZQI976HJqqOpQU6PHkJ8fb3tMNBFjg-Cn-pwAbaFM,88
|
23
|
+
pyloid-0.24.8.dist-info/RECORD,,
|
File without changes
|