Use an icon for the quick prop conversion buttons instead of text.

This commit is contained in:
Relintai 2023-09-03 13:15:23 +02:00
parent 201d6aa8e7
commit 62840e8517
2 changed files with 6 additions and 2 deletions

View File

@ -110,7 +110,9 @@ PropEditorPlugin::PropEditorPlugin(EditorNode *p_node) {
b->set_flat(true);
b->connect("pressed", this, "_quick_convert_button_pressed");
b->set_text("To Prop");
b->set_icon(editor->get_scene_tree_dock()->get_theme_icon("AssetLib", "EditorIcons"));
//b->set_text("To Prop");
b->set_tooltip(TTR("To Prop") + "\n" + TTR("Quick convert this scene to a Prop Resource."));
b->set_shortcut(ED_SHORTCUT("spatial_editor/quick_prop_convert", "Quick convert scene to PropData.", KEY_MASK_ALT + KEY_U));
add_control_to_container(EditorPlugin::CONTAINER_SPATIAL_EDITOR_MENU, bc);

View File

@ -108,7 +108,9 @@ Prop2DEditorPlugin::Prop2DEditorPlugin(EditorNode *p_node) {
b->set_flat(true);
b->connect("pressed", this, "_quick_convert_button_pressed");
b->set_text("To Prop2D");
b->set_icon(editor->get_scene_tree_dock()->get_theme_icon("AssetLib", "EditorIcons"));
//b->set_text("To Prop2D");
b->set_tooltip(TTR("To Prop") + "\n" + TTR("Quick convert this scene to a Prop 2D Resource."));
b->set_shortcut(ED_SHORTCUT("spatial_editor/quick_prop_convert", "Quick convert scene to Prop2DData.", KEY_MASK_ALT + KEY_U));
add_control_to_container(EditorPlugin::CONTAINER_CANVAS_EDITOR_MENU, bc);