Replace Ctrl in editor shortcuts with Cmd or Ctrl depending on platform
This commit is contained in:
parent
571cd0eb79
commit
6afadbaa9f
25 changed files with 54 additions and 50 deletions
|
|
@ -2217,7 +2217,7 @@ TileMapEditorTilesPlugin::TileMapEditorTilesPlugin() {
|
|||
paint_tool_button->set_toggle_mode(true);
|
||||
paint_tool_button->set_button_group(tool_buttons_group);
|
||||
paint_tool_button->set_shortcut(ED_SHORTCUT("tiles_editor/paint_tool", TTR("Paint"), Key::D));
|
||||
paint_tool_button->set_tooltip_text(TTR("Shift: Draw line.") + "\n" + TTR("Shift+Ctrl: Draw rectangle."));
|
||||
paint_tool_button->set_tooltip_text(TTR("Shift: Draw line.") + "\n" + keycode_get_string((Key)KeyModifierMask::CMD_OR_CTRL) + TTR("Shift: Draw rectangle."));
|
||||
paint_tool_button->connect("pressed", callable_mp(this, &TileMapEditorTilesPlugin::_update_toolbar));
|
||||
tilemap_tiles_tools_buttons->add_child(paint_tool_button);
|
||||
viewport_shortcut_buttons.push_back(paint_tool_button);
|
||||
|
|
@ -2263,7 +2263,8 @@ TileMapEditorTilesPlugin::TileMapEditorTilesPlugin() {
|
|||
picker_button->set_flat(true);
|
||||
picker_button->set_toggle_mode(true);
|
||||
picker_button->set_shortcut(ED_SHORTCUT("tiles_editor/picker", TTR("Picker"), Key::P));
|
||||
picker_button->set_tooltip_text(TTR("Alternatively hold Ctrl with other tools to pick tile."));
|
||||
Key key = (OS::get_singleton()->has_feature("macos") || OS::get_singleton()->has_feature("web_macos") || OS::get_singleton()->has_feature("web_ios")) ? Key::META : Key::CTRL;
|
||||
picker_button->set_tooltip_text(vformat(TTR("Alternatively hold %s with other tools to pick tile."), find_keycode_name(key)));
|
||||
picker_button->connect("pressed", callable_mp(CanvasItemEditor::get_singleton(), &CanvasItemEditor::update_viewport));
|
||||
tools_settings->add_child(picker_button);
|
||||
viewport_shortcut_buttons.push_back(picker_button);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue