Skip to content

Commit

Permalink
fix: use click count when triggering mouse click
Browse files Browse the repository at this point in the history
  • Loading branch information
socsieng committed Jan 1, 2021
1 parent 32964a7 commit f824a98
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions Sources/SendKeysLib/MouseController.swift
Expand Up @@ -34,6 +34,7 @@ class MouseController {
}

let downEvent = CGEvent(mouseEventSource: nil, mouseType: downMouseType, mouseCursorPosition: resolvedLocation, mouseButton: button)
downEvent?.setIntegerValueField(.mouseEventClickState, value: Int64(clickCount))
downEvent?.flags = flags
downEvent?.post(tap: CGEventTapLocation.cghidEventTap)

Expand Down

0 comments on commit f824a98

Please sign in to comment.