mirror of
https://github.com/Relintai/props_2d.git
synced 2025-02-04 16:15:57 +01:00
Moved the prop convert button to the canvas editor. Also changed it's style.
This commit is contained in:
parent
3c9ae1a391
commit
38a3678422
@ -118,19 +118,13 @@ Prop2DEditorPlugin::Prop2DEditorPlugin(EditorNode *p_node) {
|
|||||||
#else
|
#else
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
HBoxContainer *container = memnew(HBoxContainer);
|
|
||||||
|
|
||||||
container->add_child(memnew(VSeparator));
|
|
||||||
|
|
||||||
Button *b = memnew(Button);
|
Button *b = memnew(Button);
|
||||||
container->add_child(b);
|
|
||||||
b->set_flat(true);
|
|
||||||
|
|
||||||
b->CONNECT("pressed", this, Prop2DEditorPlugin, _quick_convert_button_pressed);
|
b->CONNECT("pressed", this, Prop2DEditorPlugin, _quick_convert_button_pressed);
|
||||||
b->set_text("To Prop2D");
|
b->set_text("To Prop2D");
|
||||||
b->set_shortcut(ED_SHORTCUT("spatial_editor/quick_prop_convert", "Quick convert scene to Prop2DData.", KEY_MASK_ALT + KEY_U));
|
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_SPATIAL_EDITOR_MENU, container);
|
add_control_to_container(EditorPlugin::CONTAINER_CANVAS_EDITOR_MENU, b);
|
||||||
}
|
}
|
||||||
|
|
||||||
Prop2DEditorPlugin::~Prop2DEditorPlugin() {
|
Prop2DEditorPlugin::~Prop2DEditorPlugin() {
|
||||||
|
Loading…
Reference in New Issue
Block a user