Fix: ToggleRecord not updating label

This commit is contained in:
Core447 2024-03-27 10:21:57 +01:00
parent 174e0b7a6d
commit 5649f398ac
No known key found for this signature in database
GPG Key ID: 5B97C0BD62F98516
1 changed files with 4 additions and 2 deletions

View File

@ -51,19 +51,21 @@ class ToggleRecord(OBSActionBase):
2: Paused
3: Stopping in progress
"""
if state in [1, 2]:
self.show_rec_time()
if state == self.current_state:
return
self.current_state = state
image = "record_inactive.png"
if state == 0:
self.set_bottom_label(None)
image = "record_inactive.png"
elif state == 1:
self.show_rec_time()
image = "record_active.png"
print("active")
elif state == 2:
self.show_rec_time()
image = "record_resume.png"
self.set_media(media_path=os.path.join(self.plugin_base.PATH, "assets", image))