Skip to content

Commit 3862170

Browse files
committed
Chore: Move resume_from_suspend arg to open
1 parent ce5268d commit 3862170

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/StreamDeck/Devices/StreamDeck.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ class StreamDeck(ABC):
7878
DECK_VISUAL = False
7979
DECK_TOUCH = False
8080

81-
def __init__(self, device, resume_from_suspend: bool = True):
81+
def __init__(self, device):
8282
self.device = device
8383
self.last_key_states = [False] * (self.KEY_COUNT + self.TOUCH_KEY_COUNT)
8484
self.last_dial_states = [False] * self.DIAL_COUNT
@@ -280,7 +280,7 @@ def _setup_reader(self, callback):
280280
self.read_thread.daemon = True
281281
self.read_thread.start()
282282

283-
def open(self):
283+
def open(self, resume_from_suspend: bool = True):
284284
"""
285285
Opens the device for input/output. This must be called prior to setting
286286
or retrieving any device state.
@@ -290,7 +290,7 @@ def open(self):
290290
self.device.open()
291291

292292
self._reset_key_stream()
293-
if self.resume_from_suspend:
293+
if resume_from_suspend:
294294
self._setup_reader(self._read_with_resume_from_suspend)
295295
else:
296296
self._setup_reader(self._read)

0 commit comments

Comments
 (0)