зеркало из https://github.com/electron/electron.git
fix: only notify mouse-up on mouse-up (#24240)
This commit is contained in:
Родитель
3853fd3e99
Коммит
acb64a2d3c
|
@ -131,10 +131,6 @@
|
|||
}
|
||||
|
||||
- (void)handleClickNotifications:(NSEvent*)event {
|
||||
trayIcon_->NotifyMouseUp(
|
||||
gfx::ScreenPointFromNSPoint([event locationInWindow]),
|
||||
ui::EventFlagsFromModifiers([event modifierFlags]));
|
||||
|
||||
// If we are ignoring double click events, we should ignore the `clickCount`
|
||||
// value and immediately emit a click event.
|
||||
BOOL shouldBeHandledAsASingleClick =
|
||||
|
@ -172,6 +168,10 @@
|
|||
- (void)mouseUp:(NSEvent*)event {
|
||||
[[statusItem_ button] highlight:NO];
|
||||
|
||||
trayIcon_->NotifyMouseUp(
|
||||
gfx::ScreenPointFromNSPoint([event locationInWindow]),
|
||||
ui::EventFlagsFromModifiers([event modifierFlags]));
|
||||
|
||||
[self handleClickNotifications:event];
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче