--- a/gdk/quartz/gdkwindow-quartz.c +++ b/gdk/quartz/gdkwindow-quartz.c @@ -1213,6 +1213,15 @@ gdk_window_quartz_show (GdkWindow *window, gboolean already_mapped) if (impl->transient_for && !GDK_WINDOW_DESTROYED (impl->transient_for)) _gdk_quartz_window_attach_to_parent (window); + if (NSPointInRect ([[impl->view window] convertScreenToBase:[NSEvent mouseLocation]], [impl->view bounds])) + { + /* When a new window (and thus view) has been created, and the mouse + * is in the window area, we will not receive an NSMouseEntered + * event. Therefore, we synthesize an enter notify event manually. + */ + _gdk_quartz_events_send_enter_notify_event (window); + } + GDK_QUARTZ_RELEASE_POOL; }