10 Commits

Author SHA1 Message Date
0fe78197fc Merge branch 'aatikturk:main' into dev 2025-02-10 12:27:07 +00:00
Adem
9c4c5a1df9 Merge pull request #53 from Zynthasius39/dev-zynt
Fix Trigger Hotkey Methods
2025-02-10 15:02:36 +03:00
f52ac163b8 patch bump version 2025-02-10 09:12:09 +00:00
Zynthasius39
197a60a7cd Fix trigger_hot_key_by_key_sequence() method 2025-02-08 18:31:12 +04:00
Zynthasius39
633093ead4 Fix trigger_hot_key_by_name() method 2025-02-08 17:59:45 +04:00
935392a0b6 Merge branch 'aatikturk:main' into dev 2025-01-25 22:34:36 +00:00
d2f2926334 Merge pull request #51 from marzeq/patch-1
Fix project.license field in pyproject.toml so that setup.py doesn't fail
2025-01-25 21:48:55 +00:00
marzeq
58cd50dd6c Fix project.license field in pyproject.toml so that setup.py doesn't fail 2025-01-25 21:34:27 +01:00
7614cdfe4a add py12 to test matrix 2024-02-21 14:15:40 +00:00
Adem
9402f2e472 Merge pull request #43 from onyx-and-iris/fix-disconnect
Add disconnect() methods. Default ws timeout to None for event thread.
2024-01-21 15:45:06 +03:00
3 changed files with 16 additions and 16 deletions

View File

@@ -138,39 +138,39 @@ class ReqClient:
get_hotkey_list = get_hot_key_list get_hotkey_list = get_hot_key_list
def trigger_hot_key_by_name(self, hotkeyName): def trigger_hot_key_by_name(self, hotkeyName, contextName=None):
""" """
Triggers a hotkey using its name. For hotkey names Triggers a hotkey using its name. For hotkey names
See GetHotkeyList See GetHotkeyList
:param hotkeyName: Name of the hotkey to trigger :param hotkeyName: Name of the hotkey to trigger
:type hotkeyName: str :type hotkeyName: str
:param contextName: Name of context of the hotkey to trigger
:type contextName: str, optional
""" """
payload = {"hotkeyName": hotkeyName} payload = {"hotkeyName": hotkeyName, "contextName": contextName}
self.send("TriggerHotkeyByName", payload) self.send("TriggerHotkeyByName", payload)
trigger_hotkey_by_name = trigger_hot_key_by_name trigger_hotkey_by_name = trigger_hot_key_by_name
def trigger_hot_key_by_key_sequence( def trigger_hot_key_by_key_sequence(
self, keyId, pressShift, pressCtrl, pressAlt, pressCmd self, keyId, pressShift=None, pressCtrl=None, pressAlt=None, pressCmd=None
): ):
""" """
Triggers a hotkey using a sequence of keys. Triggers a hotkey using a sequence of keys.
:param keyId: The OBS key ID to use. See https://github.com/obsproject/obs-studio/blob/master/libobs/obs-hotkeys.h :param keyId: The OBS key ID to use. See https://github.com/obsproject/obs-studio/blob/master/libobs/obs-hotkeys.h
:type keyId: str :type keyId: str
:param keyModifiers: Object containing key modifiers to apply. :param pressShift: Press Shift
:type keyModifiers: dict :type pressShift: bool, optional
:param keyModifiers.shift: Press Shift :param pressCtrl: Press CTRL
:type keyModifiers.shift: bool :type pressCtrl: bool, optional
:param keyModifiers.control: Press CTRL :param pressAlt: Press ALT
:type keyModifiers.control: bool :type pressAlt: bool, optional
:param keyModifiers.alt: Press ALT :param pressCmd: Press CMD (Mac)
:type keyModifiers.alt: bool :type pressCmd: bool, optional
:param keyModifiers.cmd: Press CMD (Mac)
:type keyModifiers.cmd: bool
""" """

View File

@@ -1 +1 @@
version = "1.7.0" version = "1.7.1"

View File

@@ -7,7 +7,7 @@ name = "obsws-python"
dynamic = ["version"] dynamic = ["version"]
description = "A Python SDK for OBS Studio WebSocket v5.0" description = "A Python SDK for OBS Studio WebSocket v5.0"
readme = "README.md" readme = "README.md"
license = "GPL-3.0-only" license = { text = "GPL-3.0-only" }
requires-python = ">=3.9" requires-python = ">=3.9"
authors = [ authors = [
{ name = "Adem Atikturk", email = "aatikturk@gmail.com" }, { name = "Adem Atikturk", email = "aatikturk@gmail.com" },
@@ -51,4 +51,4 @@ dependencies = [
run = 'pytest -v' run = 'pytest -v'
[[tool.hatch.envs.test.matrix]] [[tool.hatch.envs.test.matrix]]
python = ["39", "310", "311"] python = ["39", "310", "311", "312"]