ui/cocoa: Use NSTrackingInVisibleRect
commitccebb9ae352eea63cb1491cb829e4cd0f7576f1c
authorAkihiko Odaki <akihiko.odaki@daynix.com>
Sat, 23 Mar 2024 06:20:03 +0000 (23 15:20 +0900)
committerPhilippe Mathieu-Daudé <philmd@linaro.org>
Tue, 26 Mar 2024 13:32:54 +0000 (26 14:32 +0100)
tree6e0be7815daea92e97843e2f415165961d1e476d
parentf69a6f04133df61e2ab23553496a070f27f5b732
ui/cocoa: Use NSTrackingInVisibleRect

I observed [NSTrackingArea rect] becomes de-synchronized with the view
frame with some unknown condition, and fails to track mouse movement on
some area of the view. Specify NSTrackingInVisibleRect option to let
Cocoa automatically update NSTrackingArea, which also saves code for
synchronization.

Fixes: 91aa508d0274 ("ui/cocoa: Let the platform toggle fullscreen")
Signed-off-by: Akihiko Odaki <akihiko.odaki@daynix.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Message-ID: <20240323-fixes-v2-3-18651a2b0394@daynix.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
ui/cocoa.m