streamdeck-gui-ng 4.1.3__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.
Files changed (62) hide show
  1. streamdeck_gui_ng-4.1.3.dist-info/METADATA +141 -0
  2. streamdeck_gui_ng-4.1.3.dist-info/RECORD +62 -0
  3. streamdeck_gui_ng-4.1.3.dist-info/WHEEL +4 -0
  4. streamdeck_gui_ng-4.1.3.dist-info/entry_points.txt +4 -0
  5. streamdeck_gui_ng-4.1.3.dist-info/licenses/LICENSE +21 -0
  6. streamdeck_ui/__init__.py +6 -0
  7. streamdeck_ui/api.py +712 -0
  8. streamdeck_ui/button.ui +1214 -0
  9. streamdeck_ui/cli/__init__.py +0 -0
  10. streamdeck_ui/cli/commands.py +191 -0
  11. streamdeck_ui/cli/server.py +292 -0
  12. streamdeck_ui/config.py +244 -0
  13. streamdeck_ui/dimmer.py +93 -0
  14. streamdeck_ui/display/__init__.py +0 -0
  15. streamdeck_ui/display/background_color_filter.py +41 -0
  16. streamdeck_ui/display/display_grid.py +265 -0
  17. streamdeck_ui/display/empty_filter.py +43 -0
  18. streamdeck_ui/display/filter.py +65 -0
  19. streamdeck_ui/display/image_filter.py +144 -0
  20. streamdeck_ui/display/keypress_filter.py +63 -0
  21. streamdeck_ui/display/pipeline.py +74 -0
  22. streamdeck_ui/display/pulse_filter.py +54 -0
  23. streamdeck_ui/display/text_filter.py +142 -0
  24. streamdeck_ui/fonts/roboto/LICENSE.txt +202 -0
  25. streamdeck_ui/fonts/roboto/Roboto-Black.ttf +0 -0
  26. streamdeck_ui/fonts/roboto/Roboto-BlackItalic.ttf +0 -0
  27. streamdeck_ui/fonts/roboto/Roboto-Bold.ttf +0 -0
  28. streamdeck_ui/fonts/roboto/Roboto-BoldItalic.ttf +0 -0
  29. streamdeck_ui/fonts/roboto/Roboto-Italic.ttf +0 -0
  30. streamdeck_ui/fonts/roboto/Roboto-Light.ttf +0 -0
  31. streamdeck_ui/fonts/roboto/Roboto-LightItalic.ttf +0 -0
  32. streamdeck_ui/fonts/roboto/Roboto-Medium.ttf +0 -0
  33. streamdeck_ui/fonts/roboto/Roboto-MediumItalic.ttf +0 -0
  34. streamdeck_ui/fonts/roboto/Roboto-Regular.ttf +0 -0
  35. streamdeck_ui/fonts/roboto/Roboto-Thin.ttf +0 -0
  36. streamdeck_ui/fonts/roboto/Roboto-ThinItalic.ttf +0 -0
  37. streamdeck_ui/gui.py +1423 -0
  38. streamdeck_ui/icons/add_page.png +0 -0
  39. streamdeck_ui/icons/cross.png +0 -0
  40. streamdeck_ui/icons/gear.png +0 -0
  41. streamdeck_ui/icons/horizontal-align.png +0 -0
  42. streamdeck_ui/icons/remove_page.png +0 -0
  43. streamdeck_ui/icons/vertical-align.png +0 -0
  44. streamdeck_ui/icons/warning_icon_button.png +0 -0
  45. streamdeck_ui/logger.py +11 -0
  46. streamdeck_ui/logo.png +0 -0
  47. streamdeck_ui/main.ui +407 -0
  48. streamdeck_ui/mock_streamdeck.py +204 -0
  49. streamdeck_ui/model.py +78 -0
  50. streamdeck_ui/modules/__init__.py +0 -0
  51. streamdeck_ui/modules/fonts.py +150 -0
  52. streamdeck_ui/modules/keyboard.py +447 -0
  53. streamdeck_ui/modules/utils/__init__.py +0 -0
  54. streamdeck_ui/modules/utils/timers.py +35 -0
  55. streamdeck_ui/resources.qrc +10 -0
  56. streamdeck_ui/resources_rc.py +324 -0
  57. streamdeck_ui/semaphore.py +38 -0
  58. streamdeck_ui/settings.ui +155 -0
  59. streamdeck_ui/stream_deck_monitor.py +157 -0
  60. streamdeck_ui/ui_button.py +421 -0
  61. streamdeck_ui/ui_main.py +267 -0
  62. streamdeck_ui/ui_settings.py +119 -0
@@ -0,0 +1,35 @@
1
+ from functools import partial
2
+
3
+ from PySide6.QtCore import QTimer
4
+
5
+
6
+ def debounce(timeout=500):
7
+ """
8
+ Decorator to debounce a function call.
9
+ Each decorated function will have its own QTimer.
10
+ """
11
+
12
+ def decorator(func):
13
+ timer = QTimer()
14
+ timer.setSingleShot(True)
15
+
16
+ def partial_func(*args, **kwargs):
17
+ try:
18
+ timer.timeout.disconnect()
19
+ except BaseException: # noqa: B036
20
+ pass
21
+ return func(*args, **kwargs)
22
+
23
+ def wrapped(*args, **kwargs):
24
+ if timer.isActive():
25
+ timer.stop()
26
+ try:
27
+ timer.timeout.disconnect()
28
+ except BaseException: # noqa: B036
29
+ pass
30
+ timer.timeout.connect(partial(partial_func, *args, **kwargs))
31
+ timer.start(timeout)
32
+
33
+ return wrapped
34
+
35
+ return decorator
@@ -0,0 +1,10 @@
1
+ <RCC>
2
+ <qresource prefix="/icons">
3
+ <file>icons/horizontal-align.png</file>
4
+ <file>icons/cross.png</file>
5
+ <file>icons/gear.png</file>
6
+ <file>icons/vertical-align.png</file>
7
+ <file>icons/add_page.png</file>
8
+ <file>icons/remove_page.png</file>
9
+ </qresource>
10
+ </RCC>
@@ -0,0 +1,324 @@
1
+ # Resource object code (Python 3)
2
+ # Created by: object code
3
+ # Created by: The Resource Compiler for Qt version 6.5.3
4
+ # WARNING! All changes made in this file will be lost!
5
+
6
+ from PySide6 import QtCore
7
+
8
+ qt_resource_data = b"\
9
+ \x00\x00\x049\
10
+ \x89\
11
+ PNG\x0d\x0a\x1a\x0a\x00\x00\x00\x0dIHDR\x00\
12
+ \x00\x00\x18\x00\x00\x00\x18\x08\x06\x00\x00\x00\xe0w=\xf8\
13
+ \x00\x00\x00\x19tEXtSoftware\
14
+ \x00Adobe ImageRead\
15
+ yq\xc9e<\x00\x00\x03\xdbIDATx\xda\xb4\
16
+ VMHTQ\x14>3o4g*R\xe9\xc7n\
17
+ \x10\xb5)\x15\x0c\xe9\x16L\xe9P\x86\xe2\x18FE\x14\
18
+ Q\x10\xad\x86 h\xd1\xa6MK\x97mZE\xed\x8a\
19
+ \x886\x11\xad\x8a@\xb0 \x87\x19|jjX6I\
20
+ \x09\xea\x8c\xc3\xcc\xd8\xa4\xf6\xd4\x99y\x9ds\xd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xf7\x16\x8bk\xc8\x1f;\xc85\x19UQ\x8a\x8c\x22\
64
+ \xd9!\x97H\x13\xce\x07eN(\x18\xad\xd9R\xbb\x7f\
65
+ \xbd\xa6\x86;\x0d\x09\xf7\x90\xdc\x94\xe4\xf4>\xbfF|\
66
+ @l\xa6\x84\xa33\x95\xa6\x8ed-.\x11\x12\x8d\xe2\
67
+ :\x05\xa6\xed\xb0\x8c\xa7p\xa1\xe1\x18n\xa8d\xdf\x91\
68
+ \xe4I\xc4\x1b\x9c\xc7\x11y\x89q\xc4\x8c\x14\x09\xe0\x93\
69
+ \xc8\xfe\xe0{\x1b\x83J\x88s\xd4!\xda\xf1\xabv\x09\
70
+ ``\xa2\xa6\xc6\xa4'\xce#u\xff\xf0\xad\x94\xbe\x11\
71
+ \x97o\xb8\xce\xf1\xfd\xaeX\x00\xd84\x09\xf0\x1d\x8f7\
72
+ 7b\x18\xbb\xa7\x01\x9e\xf7a\x97\xc0\xf5Zy#~\
73
+ \xaaT\xf9\x92\xd3\x93\x02\xafFlC\x9b\x9d\xe8\x9b\xc2\
74
+ Iq\xc00\xb6|\x02\xb8\x8b\xdd\xa1\x7fA~\x05T\
75
+ \x85\xfa\xa4\xa3\xea\x14\x1e+5\xa2\x9c\x0b\x12E\xb9\xa6\
76
+ ~,h\x8e\xae\xa2~\x5c\x94d\xc7X\x96\xdd\xa2\xf0\
77
+ K\x80\x01\x00\x9en\x09\xdb\x0f\x1d\x92\xbe\x00\x00\x00\x00\
78
+ IEND\xaeB`\x82\
79
+ \x00\x00\x01t\
80
+ \x89\
81
+ PNG\x0d\x0a\x1a\x0a\x00\x00\x00\x0dIHDR\x00\
82
+ \x00\x00\x18\x00\x00\x00\x18\x08\x06\x00\x00\x00\xe0w=\xf8\
83
+ \x00\x00\x00\x09pHYs\x00\x00\x0b\x13\x00\x00\x0b\x13\
84
+ \x01\x00\x9a\x9c\x18\x00\x00\x01&IDATx\x9c\xdd\
85
+ TKN\x02A\x10\x9d`\xe4B\xde\xc2.\xa8B\x18\
86
+ \xb9\x81\xd7\x98-\x1f/\xe0Z3\x10\x17U\xdcf\x90\
87
+ \x8fw \xb0\xd7\x142$f\x9a)h\xdb\x85V\xf2\
88
+ \x92I\xa7\xe7\xbd\xae\xf7\xba+I\xfeu\xa5\xafi\x13\
89
+ \x04\xfbN0wLs`\xda)\xf4[\xd7ZL\xf7\
90
+ \xba'\x88\x1c\x04\xbb \xb8\x06\xa1\x8fz\xe0\xea\x96\xe9\
91
+ \xee\x92S_\x01\xd3\xa3ML\xdf\xe0\x98\xc6Y\x965\
92
+ \xec\x93\x07\x90C\x09\xa6\xe1\x19\xb6\x04\x92\xcb\xd12\xaa\
93
+ \x0btU\xf7s^L\xf70\xacz\xf7\x06\xaf\xb7\xc5\
94
+ :]Yv\x1e\x9d\xd4'0\x89%\x00\x82/>\x81\
95
+ E\xbc\x0eh^\x11p\x82[\x9f\xe7V\xf92Q\xae\
96
+ _\x15\x00\xa6\x8d\xcf\xa2\xb7h\x16\x09\x16\xbe\x0e\xf2\x88\
97
+ !?W\x04tpE\xeb`\xd6\xeeU\x04n\x9e\x1e\
98
+ \xae\x1d\xd3\xf2\xa7\x0f\x0d\x04\xd7''\xacNE\xbb}\
99
+ \xaaE\x8b\x09\xbd\xe4\xc7,\x98\xc6\xc1\x02L\x83\xc4*\
100
+ \x1d\xb9Np\x14@><k\x5c\x97\xa5S\xd1\xca\xe4\
101
+ \xf0j\x97\xa6-\xa7\xea+\xf8N\xaa\xb3E\xef\xb6>\
102
+ \xc6\x03\x8a\xfd\xda\xac\xdd\xd3=A\xe4\x7f\xa6>\x01\x7f\
103
+ \x1a*y\xbc\xbf\x955\x00\x00\x00\x00IEND\xae\
104
+ B`\x82\
105
+ \x00\x00\x00\xec\
106
+ \x89\
107
+ PNG\x0d\x0a\x1a\x0a\x00\x00\x00\x0dIHDR\x00\
108
+ \x00\x00\x1a\x00\x00\x00\x1a\x08\x04\x00\x00\x00\x03C\x84E\
109
+ \x00\x00\x00\xb3IDAT8\xcbc`\xa0\x1c8\x80\
110
+ 0\xa3\x03\x0b\x90\x9c\xe20\x11H\xb280BD\x89\
111
+ \xd1R\xe7\xf0\x1f\x08k\x08jC\xd2\xd2\x08\xd4\xf0\x07\
112
+ \x08\xff;\xd4\x13\xa1\x0d\xac\xb1\x16\xa8\xf8\xa7\xc3? \
113
+ \xfc\x09dU\x81\x8d\xc2\xa3\x85\xc9\x81\xc3a2\xd8a\
114
+ \xc8p\xa2\x03;P\x06\x87&\x90#\xe4\x1dZ\x1c\xaa\
115
+ \x1d\xaa\x1c\xce\x81\x95\x9f\x03\xb2\xaa\x81\x22\xb2\x10Y\x9c\
116
+ \xbe\x82\xb2f\x825\xcd$\x22\xb8\x1d\xc0\x01\x01t\x22\
117
+ \x8b\xc3\x22\xb0\xa6EP\x1e\xa3\x03\xa1`\x07\x87\xdf\x02\
118
+ \xb0\xa6\x05\xe0\xb0#&zG5\xd1M\x13\x99\x91K\
119
+ N2\x22'\xc1\x92\x955\xc8\xcc\x84dfw\x92\x0b\
120
+ \x162\x8b0b\x01\x00\xb7\xde\xa5\xf5\xa1bS{\x00\
121
+ \x00\x00\x00IEND\xaeB`\x82\
122
+ \x00\x00\x05=\
123
+ \x89\
124
+ PNG\x0d\x0a\x1a\x0a\x00\x00\x00\x0dIHDR\x00\
125
+ \x00\x00\x18\x00\x00\x00\x18\x08\x06\x00\x00\x00\xe0w=\xf8\
126
+ \x00\x00\x00\x19tEXtSoftware\
127
+ \x00Adobe ImageRead\
128
+ yq\xc9e<\x00\x00\x04\xdfIDATx\xda\xb4\
129
+ U]L\x9be\x14>\xfd\x87V\xba\x96\xd22\x08#\
130
+ \x19\xcb4\x8b\xd94Qf\x82\x8af@\x8a4\x5cL\
131
+ \x1d\x5cL#\xe1nD\xaa\xd1\xab\x11\x22\x81\x90\xe8\x85\
132
+ Q,\x86lW\xb2M\x09ht!$\x1d\x1d-1\
133
+ F\xb8\xda2\x98\x17K\x81a\xc6XX\xf8i+\x7f\
134
+ \xed\xd7B\xeby\xde\xef\xfb\xba\x8eh\xe2\x8d_r\xfa\
135
+ \x9e\x9e\x9f\xe7\xbc\xefy\xcf9\xaf&\x93\xc9\xd0\xff\xf9\
136
+ \xe9\xf1\xd3\xd8\xd8H\x1a\x8d\x86t:\x9d\xa0\xdcO\xab\
137
+ \xd5by\x8b\xc9\xcedV\xc4\xbbLQ\xa6\x1b\xe9t\
138
+ \xfa)\xfb\xfd\xfd}A\xd8\xf8\xd8\xd8\x98\x1c\xe0\xc0\xf7\
139
+ 2\xd3KL\x93l8\xaf\xc8\xca\x07\x07\x07{\xcdf\
140
+ \xb3M\xa0\xef\xee\xc6ZZZ:U@\xde\xd4qf\
141
+ \xcf0\xddf\xba\xf5\xd4\x06\x0f\x80W\xb2C\xe5\xf0\xf0\
142
+ \xf0%^k\xf9\xff\xf1T*\x05\x10m<\x1e/Z\
143
+ XX\xd0\x83\xc0C\x06\x1dl`\xab\xf8T\x02\xe3\xdf\
144
+ \x02\x9c\x86\xc1\xd0\xd0\xd0@8\x1c&\xac\xfc\xbf\x8e\x8f\
145
+ \xda\xc6\xab\x06`\xb9\x04\x99\xa2\xab;\xe0\x83\x00\xa7U\
146
+ P\x18QCC\x03\xf8\x0f\x07\x06\x06\xfa\xa3\xd1h6\
147
+ bEE\x05\xf5\xf3W__\xfffII\xc9II\
148
+ \x92\x84\xdcd2\xd1\xca\xca\xca\x1f\xe3\xe3\xe3\xbf\xb6\xf3\
149
+ \xb7\xb8\xb8\x98\xf5\xb1\xdb\xed\xd4\xd6\xd6\xd6\xce\xec\xb7~\
150
+ \xbf_\x0e\xe0v\xbb\xa1{\x96\xc9\xdd\xdf\xef\xf3\xa9A\
151
+ \x8cF\x139\x1c\x85\x827\x18\x8c\xd9\x02@\xdeS\xa9\
152
+ \xa4\xe076\x22\x94LJY\xf0\xf6v\xaf\x97\xd9\x00\
153
+ \xd3\x5c \x10\x90/\x99s\xca`\xc69\x9c\xe8\xc2\x85\
154
+ \xb6\x8f\xfb\xfa\xbe\xee\xdb\xd9\xd9aP=\xa1J67\
155
+ 7iii\x89\xd4\xc0\x00*//'\xab\xd5*l\
156
+ $)A\x16\x8b\x85\xe0\xcb\xd5x\x13\xe0\xc9d\xf2\xc9\
157
+ \x1d`G\x08\xc2)\x08s~\xb5W\xaf^\x1b\x80\x83\
158
+ F\xa3\xa5\xfb\xf7\x17\xe9\xce\x9d\x19\x11\xa8\xb8\xb8X\x10\
159
+ x\xc8\xa0\x83\x0dl\xe1\x03_`\x00\x0b\x98\xd9>\xe0\
160
+ 4\xbd\xcd\xcbQUX]\xfd\xfa\x1b\xdb\xdb\xdb\x22\x0d\
161
+ \xcb\xcb\x0f\xa9\xa0\xa0 9::\xfa\xdb\xc4D\xf0\x1e\
162
+ \xf4uu\xb5'<\x1eO5\xeb\x8c\x06\x83N\xa4\x0f\
163
+ >SSS\xb8\x8cO\x95\xeb\xf8\x93\xe9\x17\x11`o\
164
+ o\xaf\xc8\xe7\xfb\xe6\x22\xef\xc4\xa1\xa6\x0c\x17\xba\xb2\xf2\
165
+ X\xec\xce\xef\xbf118x\xe5;\xf4\x06\xf4\xcc\x9f\
166
+ \xe1\x9dK\xf5\xf5n\x0flJKKq\xb2\xe7/_\
167
+ \xbe\xf4%\xf4\x9c\xde\x0d\xaf\xf7\xa3\x8el\x8a\xf8hV\
168
+ \xde\x85mnn\x9e@\xeb\xeb\xeb\xa2\x14\xe3\xf1\x04\xdf\
169
+ M\x1e\x85B!4OP\xe9^P\x102\xe8`\x03\
170
+ [\xf8\xa8\xfe\xc0\x02f6E|\x02-\xf2\xaa\xb6}\
171
+ :\x9d!\x8c(\x8c\x09\x93\xc9\xcc\xabn\xff\xe0\xcc\x82\
172
+ L\xd6E\x85-|\x9e\xf8\xa7\x05f\xee\x09\xb8\xfbw\
173
+ \xff\xb2\xdb\x0b\x09\x94\x9foaG=\xaffqYM\
174
+ M\xe7_`\xb3*\x0eb\x05\x81\x87\x0c:\xd8\xc8\xb6\
175
+ \x16R\xfd\x81\x05\xcc\xec\x09\xf8O\xa4\xb5\xb5\xb5O\xdd\
176
+ ]ww\xef\xf9#G\xca\x9fs8\x5c\xb4\xb6\xb6J\
177
+ \xcd\xcd\xefy8\x1d\x99\x91\x91k'\xa1on~\xbf\
178
+ \xf2\xec\xd9w=\xe1\xf0,9\x9d.\x9c\x86\x1e=Z\
179
+ \x0awuu\xfe\x90s\xc8H\xb6\x93\xd1\xb1j\xb9\xf2\
180
+ \xd7UU\xf5\xdaQ\xaf\xf7\x93\x0f\xf2\xf2\xcc\x14\x89\xac\
181
+ \xd3\xd6\xd6\x16\x1d;v\x82\x0a\x0b]\xb2gd\x95K\
182
+ \xf4\x1e\xaa\x8beE\x94H\xec\x92\xcf\xf7\xd5\x95\xe9\xe9\
183
+ \xdfQ9\xddjC\xa2\xc3E\x80\xb2\xb22Bc\xe8\
184
+ \xf5\xfaS\xdc(\xef\xf8\xfd\xc1\xcfP\x1d6\x9bC9\
185
+ \xf2\x0e\x9f\xe41\x8e.\x1cy\xaa\xf2\xce\x0f\xf3j\xe1\
186
+ \xe6\x8bP,\xb6A%%\x87y\xe4\xd4\xf60\xde\xcf\
187
+ \x9c\xff\xbb\xdc\xb8\x5c\xe2\xcbr\x00\xa7\xd3\x89\xf7\xe0\x14\
188
+ \xfb\x9e\x0b\x85\xa6;\xd5\xd9b6?C.\x97\x8b/\
189
+ :_\x80\xea\xf5\x06\x92\x8b\x22%\x82IR\x9cVW\
190
+ W\x99\xdf\xce\xce\xae\x9a\x9a\xaa^f\x7fb\xdc\xbbk\
191
+ kk\xf2%\xe3\xd69=M\xd7\xaf\xdf\xec|\xf0\xe0\
192
+ !\xcf\x1c\x83 \x80\xf6\xf4t|?;{{>\x16\
193
+ \x8b\x0a0\x10x\xc8\xa0\x83\x8dj\x0f_`\x00K\xad\
194
+ (q\x02\x9bM\xbc#5\xcc\xd7\x04\x02\xd3\x171s\
195
+ 0o\xdc\xee\xaa\xcf\xd5\x1bS\xe5\xea,\xfa'\x9d*\
196
+ \xe7l\x84X\x1c\x8a\xc5b\xf2\x09\xd0\xb5\x9c\xb7\x10G\
197
+ \x9d\xac\xad}\xe5\x8b\xa2\x22'a\xe5\xff?r\xd0\x0e\
198
+ \xcc~\x9dNO\xb9\xa4\xbc\x07\x1d\xb09\xe03\x09,\
199
+ u\xb4\x8b2M$\x12\xe2\x0f\xdf~\x90/ZS]\
200
+ \xfd\xa2\x96\x9dG\xd8pF\x1e\xd5\x06m\x22!\xc5\x0e\
201
+ \x1d\xb2\x17\xc8\xf6\xd2\x16^4\xc5o\x86}H\xf1\x01\
202
+ xP\x9di\xd9\x14i0\x12\x89,Lh\xa2\x02\xe5\
203
+ q\xd7\xa8F\x1c\xe0U\xb6\xb1*6b\xdc\xb0\xdf&\
204
+ \xf7\xcfTN\xdd#\xe9;L\x9b\x0a\xc5\xd9&\xa3\x06\
205
+ \x00\x98\x11\x8f\x95\xb2\x1ar\x03\xfc\xc7\x0f\xb3\x04\x8f\x80\
206
+ \xa4\xd0\x1e\x02\xfc-\xc0\x00\xc9p\x09&<N\x86\x1b\
207
+ \x00\x00\x00\x00IEND\xaeB`\x82\
208
+ \x00\x00\x00\xfa\
209
+ \x89\
210
+ PNG\x0d\x0a\x1a\x0a\x00\x00\x00\x0dIHDR\x00\
211
+ \x00\x00\x18\x00\x00\x00\x18\x08\x06\x00\x00\x00\xe0w=\xf8\
212
+ \x00\x00\x00\x09pHYs\x00\x00\x0b\x13\x00\x00\x0b\x13\
213
+ \x01\x00\x9a\x9c\x18\x00\x00\x00\xacIDATx\x9c\xed\
214
+ \x94\xc1\x0e\x820\x10D\xfbS\xbb\x9c\xdb\xe5`\xc4\xa8\
215
+ \xff\xff\x1b\x1d\x22\xd8\x83\x06c\x88\x22\x91\x05\xb7\xc4\x03\
216
+ {\x9ey\x93n\xdbqn\x9b\xbf\x9cZ\xf8\x04\xa1\x83\
217
+ V\x8f\x92\xab\xce\xa3\x13\xfbb\x1f\x0371p\xab1\
218
+ Ah\x17\x85.Q\xf8Z\x07>;\xad\x01\xc2\xb7\xa9\
219
+ \x90\x0f\xad/\x8e\xbaS(\x8cX\x0a\xd7\x00\xf0+\xfc\
220
+ \x1b\x08V\xf0\xf1\x10J\x08\xdc\x9a\xc1\x07!\x0f\xf0\x13\
221
+ \x9e\xcc\xe0\xe3\x01d\x17\x80\xd7\x15\x09\xa5(\x86+\xca\
222
+ z\xc9Y\x9f)r~4\xcc0bI\xc8[\xd9\xf9\
223
+ iC_v\x9d^Sv}]\x97\x5c\xa9\xc4s\xeb\
224
+ z\x9b\xd5\xe7\x0eX\x5c\x16\xabz\xa9\xb8\x5c\x00\x00\x00\
225
+ \x00IEND\xaeB`\x82\
226
+ \x00\x00\x02\x15\
227
+ \x89\
228
+ PNG\x0d\x0a\x1a\x0a\x00\x00\x00\x0dIHDR\x00\
229
+ \x00\x00\x1a\x00\x00\x00\x1a\x08\x04\x00\x00\x00\x03C\x84E\
230
+ \x00\x00\x00\x02bKGD\x00\xff\x87\x8f\xcc\xbf\x00\x00\
231
+ \x00\x07tIME\x07\xe7\x06\x01\x0a3\x05y\xff\x07\
232
+ 6\x00\x00\x01%IDAT8\xcb\xed\x931n\x02\
233
+ 1\x10E\x9f\xd7\xd6\x22\xaa\x9c\x00q\x86\x14\xe9\xffe\
234
+ R\x85\x5c\x80\x00+HB\x93\x0e%\xf7\x99>E\xce\
235
+ \x92\x0a\x89\xd88\x85\x91`\x97\x8d\x14z\xfe4\x1e\x8d\
236
+ \x9e<3\xfe\x86\xabN%@\xc8\x95SO\xcd\x89N\
237
+ \xed\x80T\xa0^H\x80\xaa#V\x810\xe4\x80Zc\
238
+ \x03wF9Ccj\x903\x04\x04\x0a\xe2-\xea\x8d\
239
+ ofx\xc5\x0e\xe4\x89\xdcsc\x8f\xf2J\x96\xcbM\
240
+ \x05\x993a\x0b\x84\x9e\x80-\x13\xcd-\xe2\xe5 \x00\
241
+ \xde\xa2\x96,\x80\x0cD\x8b\xdd\x99\x0e\x95\x95\x825\x0a\
242
+ D\x07\xa0\x05Kv\xd4|\xf1\xc9\x90}\xa7\xbd\x8a-\
243
+ w\xdc\xb2\xa3\xa6\xb1\x158\xd0;\x0f$\xaa\x9e\x15\xb4\
244
+ \x95\xd9\xe3\xf9\xb0I\x05\xa4\x8b\x9e4\x1d\x16\xac\x19\xcf\
245
+ \xfflon/e\xd0\x00j\x94\x955-Yg\x11\
246
+ \x014UVVS\xb2\x00$\x05[\xea\x87W\x1c\x10\
247
+ \xce<\x11\x888\xe0\xc9\xd6\x0a$\xa8\xc02I\xc1\xd6\
248
+ l\x18\x02\xb1'`\xc8\xa6 \x96O\x0d\xe94\xd0\x88\
249
+ b\xa8v{\x0e4\xd2@\xaee\xe8\xa3a\xffry\
250
+ \xdb\xb0m\xec\x92\xafq\x15\xfc\x02\x07\xa6o\x93a\x86\
251
+ _\xdf\x00\x00\x00%tEXtdate:c\
252
+ reate\x002023-06-01\
253
+ T10:49:54+00:00k\
254
+ <\xc2y\x00\x00\x00%tEXtdate:\
255
+ modify\x002023-05-2\
256
+ 5T00:39:21+00:00\
257
+ U\xf3\xf2g\x00\x00\x00(tEXtdate\
258
+ :timestamp\x002023-\
259
+ 06-01T10:51:05+0\
260
+ 0:00q\xba\xc1\xfe\x00\x00\x00\x00IEND\
261
+ \xaeB`\x82\
262
+ "
263
+
264
+ qt_resource_name = b"\
265
+ \x00\x05\
266
+ \x00o\xa6S\
267
+ \x00i\
268
+ \x00c\x00o\x00n\x00s\
269
+ \x00\x09\
270
+ \x06\xa6\x82g\
271
+ \x00c\
272
+ \x00r\x00o\x00s\x00s\x00.\x00p\x00n\x00g\
273
+ \x00\x0c\
274
+ \x0b%\x1b\x87\
275
+ \x00a\
276
+ \x00d\x00d\x00_\x00p\x00a\x00g\x00e\x00.\x00p\x00n\x00g\
277
+ \x00\x12\
278
+ \x02-\x5c\xc7\
279
+ \x00v\
280
+ \x00e\x00r\x00t\x00i\x00c\x00a\x00l\x00-\x00a\x00l\x00i\x00g\x00n\x00.\x00p\x00n\
281
+ \x00g\
282
+ \x00\x08\
283
+ \x0b\x85Z\xe7\
284
+ \x00g\
285
+ \x00e\x00a\x00r\x00.\x00p\x00n\x00g\
286
+ \x00\x0f\
287
+ \x0f\x10\xd8\x87\
288
+ \x00r\
289
+ \x00e\x00m\x00o\x00v\x00e\x00_\x00p\x00a\x00g\x00e\x00.\x00p\x00n\x00g\
290
+ \x00\x14\
291
+ \x01\x9bQ\xc7\
292
+ \x00h\
293
+ \x00o\x00r\x00i\x00z\x00o\x00n\x00t\x00a\x00l\x00-\x00a\x00l\x00i\x00g\x00n\x00.\
294
+ \x00p\x00n\x00g\
295
+ "
296
+
297
+ qt_resource_struct = b"\
298
+ \x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x01\
299
+ \x00\x00\x00\x00\x00\x00\x00\x00\
300
+ \x00\x00\x00\x00\x00\x02\x00\x00\x00\x01\x00\x00\x00\x02\
301
+ \x00\x00\x00\x00\x00\x00\x00\x00\
302
+ \x00\x00\x00\x00\x00\x02\x00\x00\x00\x06\x00\x00\x00\x03\
303
+ \x00\x00\x00\x00\x00\x00\x00\x00\
304
+ \x00\x00\x00\xaa\x00\x00\x00\x00\x00\x01\x00\x00\x0c\xe4\
305
+ \x00\x00\x01\x8a\xe0\xdbb\x8b\
306
+ \x00\x00\x00F\x00\x00\x00\x00\x00\x01\x00\x00\x05\xb5\
307
+ \x00\x00\x01\x89\x93l\xe7\xcd\
308
+ \x00\x00\x00\x10\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\
309
+ \x00\x00\x01\x89\x93l\xe7\xcd\
310
+ \x00\x00\x00(\x00\x00\x00\x00\x00\x01\x00\x00\x04=\
311
+ \x00\x00\x01\x8a\xe0\xdbb\x8b\
312
+ \x00\x00\x00p\x00\x00\x00\x00\x00\x01\x00\x00\x06\xa5\
313
+ \x00\x00\x01\x89\x93l\xe7\xcd\
314
+ \x00\x00\x00\x86\x00\x00\x00\x00\x00\x01\x00\x00\x0b\xe6\
315
+ \x00\x00\x01\x8a\xe0\xdbb\x8c\
316
+ "
317
+
318
+ def qInitResources():
319
+ QtCore.qRegisterResourceData(0x03, qt_resource_struct, qt_resource_name, qt_resource_data)
320
+
321
+ def qCleanupResources():
322
+ QtCore.qUnregisterResourceData(0x03, qt_resource_struct, qt_resource_name, qt_resource_data)
323
+
324
+ qInitResources()
@@ -0,0 +1,38 @@
1
+ import fcntl
2
+ import os
3
+
4
+
5
+ class SemaphoreAcquireError(Exception):
6
+ pass
7
+
8
+
9
+ class Semaphore:
10
+ def __init__(self, semaphore_file):
11
+ self.semaphore_file = semaphore_file
12
+ self.semaphore_fd = None
13
+
14
+ def __enter__(self):
15
+ # create the semaphore file if it does not exist
16
+ if not os.path.exists(self.semaphore_file):
17
+ open(self.semaphore_file, "w").close()
18
+
19
+ # open the file descriptor for the semaphore file
20
+ self.semaphore_fd = os.open(self.semaphore_file, os.O_CREAT)
21
+
22
+ try:
23
+ fcntl.flock(self.semaphore_fd, fcntl.LOCK_EX | fcntl.LOCK_NB)
24
+ except OSError:
25
+ raise SemaphoreAcquireError("Could not acquire semaphore lock")
26
+
27
+ def __exit__(self, exc_type, exc_value, traceback):
28
+ # release the semaphore
29
+ fcntl.flock(self.semaphore_fd, fcntl.LOCK_UN)
30
+
31
+ # remove semaphore file
32
+ os.remove(self.semaphore_file)
33
+
34
+ # close the file descriptor
35
+ os.close(self.semaphore_fd)
36
+
37
+ # reset the file descriptor to None
38
+ self.semaphore_fd = None
@@ -0,0 +1,155 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <ui version="4.0">
3
+ <class>SettingsDialog</class>
4
+ <widget class="QDialog" name="SettingsDialog">
5
+ <property name="windowModality">
6
+ <enum>Qt::ApplicationModal</enum>
7
+ </property>
8
+ <property name="geometry">
9
+ <rect>
10
+ <x>0</x>
11
+ <y>0</y>
12
+ <width>452</width>
13
+ <height>156</height>
14
+ </rect>
15
+ </property>
16
+ <property name="sizePolicy">
17
+ <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
18
+ <horstretch>0</horstretch>
19
+ <verstretch>0</verstretch>
20
+ </sizepolicy>
21
+ </property>
22
+ <property name="windowTitle">
23
+ <string>Stream Deck Settings</string>
24
+ </property>
25
+ <property name="windowIcon">
26
+ <iconset resource="resources.qrc">
27
+ <normaloff>:/icons/icons/gear.png</normaloff>:/icons/icons/gear.png</iconset>
28
+ </property>
29
+ <layout class="QVBoxLayout" name="verticalLayout">
30
+ <property name="leftMargin">
31
+ <number>9</number>
32
+ </property>
33
+ <item>
34
+ <layout class="QVBoxLayout" name="verticalLayout_2">
35
+ <item>
36
+ <layout class="QFormLayout" name="formLayout">
37
+ <property name="horizontalSpacing">
38
+ <number>30</number>
39
+ </property>
40
+ <property name="verticalSpacing">
41
+ <number>6</number>
42
+ </property>
43
+ <item row="0" column="0">
44
+ <widget class="QLabel" name="label">
45
+ <property name="text">
46
+ <string>Stream Deck:</string>
47
+ </property>
48
+ </widget>
49
+ </item>
50
+ <item row="0" column="1">
51
+ <widget class="QLabel" name="label_streamdeck">
52
+ <property name="text">
53
+ <string/>
54
+ </property>
55
+ </widget>
56
+ </item>
57
+ <item row="1" column="0">
58
+ <widget class="QLabel" name="label_brightness">
59
+ <property name="text">
60
+ <string>Brightness:</string>
61
+ </property>
62
+ </widget>
63
+ </item>
64
+ <item row="1" column="1">
65
+ <widget class="QSlider" name="brightness">
66
+ <property name="orientation">
67
+ <enum>Qt::Horizontal</enum>
68
+ </property>
69
+ </widget>
70
+ </item>
71
+ <item row="2" column="0">
72
+ <widget class="QLabel" name="label_dim">
73
+ <property name="text">
74
+ <string>Auto dim after:</string>
75
+ </property>
76
+ </widget>
77
+ </item>
78
+ <item row="2" column="1">
79
+ <widget class="QComboBox" name="dim">
80
+ <property name="currentText">
81
+ <string/>
82
+ </property>
83
+ </widget>
84
+ </item>
85
+ <item row="3" column="0">
86
+ <widget class="QLabel" name="label_brightness_dimmed">
87
+ <property name="text">
88
+ <string>Dim to %:</string>
89
+ </property>
90
+ </widget>
91
+ </item>
92
+ <item row="3" column="1">
93
+ <widget class="QSlider" name="brightness_dimmed">
94
+ <property name="orientation">
95
+ <enum>Qt::Horizontal</enum>
96
+ </property>
97
+ </widget>
98
+ </item>
99
+ </layout>
100
+ </item>
101
+ </layout>
102
+ </item>
103
+ <item>
104
+ <widget class="QDialogButtonBox" name="buttonBox">
105
+ <property name="orientation">
106
+ <enum>Qt::Horizontal</enum>
107
+ </property>
108
+ <property name="standardButtons">
109
+ <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
110
+ </property>
111
+ <property name="centerButtons">
112
+ <bool>false</bool>
113
+ </property>
114
+ </widget>
115
+ </item>
116
+ </layout>
117
+ </widget>
118
+ <resources>
119
+ <include location="resources.qrc"/>
120
+ </resources>
121
+ <connections>
122
+ <connection>
123
+ <sender>buttonBox</sender>
124
+ <signal>accepted()</signal>
125
+ <receiver>SettingsDialog</receiver>
126
+ <slot>accept()</slot>
127
+ <hints>
128
+ <hint type="sourcelabel">
129
+ <x>248</x>
130
+ <y>254</y>
131
+ </hint>
132
+ <hint type="destinationlabel">
133
+ <x>157</x>
134
+ <y>274</y>
135
+ </hint>
136
+ </hints>
137
+ </connection>
138
+ <connection>
139
+ <sender>buttonBox</sender>
140
+ <signal>rejected()</signal>
141
+ <receiver>SettingsDialog</receiver>
142
+ <slot>reject()</slot>
143
+ <hints>
144
+ <hint type="sourcelabel">
145
+ <x>316</x>
146
+ <y>260</y>
147
+ </hint>
148
+ <hint type="destinationlabel">
149
+ <x>286</x>
150
+ <y>274</y>
151
+ </hint>
152
+ </hints>
153
+ </connection>
154
+ </connections>
155
+ </ui>