Browse Source

Merge pull request #105822 from bruvzg/mm_update_enter

[macOS] Update entered state from `mouseMoved`.
Thaddeus Crews 4 months ago
parent
commit
c40c56b406
1 changed files with 5 additions and 0 deletions
  1. 5 0
      platform/macos/godot_content_view.mm

+ 5 - 0
platform/macos/godot_content_view.mm

@@ -532,6 +532,11 @@
 	mm->set_relative_screen_position(relativeMotion);
 	ds->get_key_modifier_state([event modifierFlags], mm);
 
+	const NSRect contentRect = [wd.window_view frame];
+	if (NSPointInRect([event locationInWindow], contentRect)) {
+		ds->mouse_enter_window(window_id);
+	}
+
 	Input::get_singleton()->parse_input_event(mm);
 }