Skip to content
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion plugin/mouse/mouse.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,4 +172,4 @@ def noise_trigger_pop():
)

if should_click:
ctrl.mouse_click(button=0, hold=16000)
actions.mouse_click()
20 changes: 20 additions & 0 deletions plugin/mouse/mouse_click_with_hold.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
from talon import Context, Module, ctrl

mod = Module()

mod.tag(
"mouse_click_with_hold",
desc="Hold mouse buttons for 16 ms so clicks register reliably",
)

ctx = Context()
ctx.matches = r"""
tag: user.mouse_click_with_hold
"""


@ctx.action_class("main")
class MainActions:
@staticmethod
def mouse_click(button: int = 0):
Comment thread
AndreasArvidsson marked this conversation as resolved.
ctrl.mouse_click(button=button, hold=16000)
3 changes: 3 additions & 0 deletions settings.talon
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ settings():
# If `true`, use a hissing noise to scroll continuously
user.mouse_enable_hiss_scroll = false

# If `true`, hold mouse buttons for 16 ms so clicks register reliably
user.mouse_click_with_hold = false
Comment thread
AndreasArvidsson marked this conversation as resolved.
Outdated

# How much time a hiss must last for to be considered a hiss rather than
# part of speech, in ms
user.hiss_scroll_debounce_time = 100
Expand Down