MacOutsideClickWatcher

class MacOutsideClickWatcher(windowSupplier: () -> <Error class: unknown class>?, onOutsideClick: () -> Unit)

MacOutsideClickWatcher: encapsulates macOS-specific logic to detect a left-click outside the provided window and invoke a callback to hide it. It also ignores clicks on the macOS status bar tray icon (status item) so that clicking the tray icon does not spuriously hide the window.

Constructors

Link copied to clipboard
constructor(windowSupplier: () -> <Error class: unknown class>?, onOutsideClick: () -> Unit)

Functions

Link copied to clipboard
open fun close()
Link copied to clipboard
fun start()
Link copied to clipboard
fun stop()