mirror of
https://github.com/godotengine/godot.git
synced 2025-12-08 06:09:55 +00:00
Merge pull request #108314 from KoBeWi/shift_in_meta
Replace repetitive meta/ctrl condition with a method
This commit is contained in:
commit
e33c423700
11 changed files with 25 additions and 13 deletions
|
|
@ -504,7 +504,7 @@ void CodeEdit::gui_input(const Ref<InputEvent> &p_gui_input) {
|
|||
}
|
||||
|
||||
/* Ctrl + Hover symbols */
|
||||
bool mac_keys = OS::get_singleton()->has_feature("macos") || OS::get_singleton()->has_feature("web_macos") || OS::get_singleton()->has_feature("web_ios");
|
||||
bool mac_keys = OS::prefer_meta_over_ctrl();
|
||||
if ((mac_keys && k->get_keycode() == Key::META) || (!mac_keys && k->get_keycode() == Key::CTRL)) {
|
||||
if (symbol_lookup_on_click_enabled) {
|
||||
if (k->is_pressed() && !is_dragging_cursor()) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue