You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-09 12:50:35 +00:00
Allow smaller horizontal size of VersionControlEditorPlugin
This commit is contained in:
@@ -44,6 +44,7 @@
|
|||||||
#include "editor/gui/editor_bottom_panel.h"
|
#include "editor/gui/editor_bottom_panel.h"
|
||||||
#include "editor/plugins/script_editor_plugin.h"
|
#include "editor/plugins/script_editor_plugin.h"
|
||||||
#include "editor/themes/editor_scale.h"
|
#include "editor/themes/editor_scale.h"
|
||||||
|
#include "scene/gui/flow_container.h"
|
||||||
#include "scene/gui/separator.h"
|
#include "scene/gui/separator.h"
|
||||||
|
|
||||||
#define CHECK_PLUGIN_INITIALIZED() \
|
#define CHECK_PLUGIN_INITIALIZED() \
|
||||||
@@ -1300,7 +1301,7 @@ VersionControlEditorPlugin::VersionControlEditorPlugin() {
|
|||||||
|
|
||||||
version_commit_dock->add_child(memnew(HSeparator));
|
version_commit_dock->add_child(memnew(HSeparator));
|
||||||
|
|
||||||
HBoxContainer *menu_bar = memnew(HBoxContainer);
|
HFlowContainer *menu_bar = memnew(HFlowContainer);
|
||||||
menu_bar->set_h_size_flags(Control::SIZE_EXPAND_FILL);
|
menu_bar->set_h_size_flags(Control::SIZE_EXPAND_FILL);
|
||||||
menu_bar->set_v_size_flags(Control::SIZE_FILL);
|
menu_bar->set_v_size_flags(Control::SIZE_FILL);
|
||||||
version_commit_dock->add_child(menu_bar);
|
version_commit_dock->add_child(menu_bar);
|
||||||
@@ -1308,6 +1309,7 @@ VersionControlEditorPlugin::VersionControlEditorPlugin() {
|
|||||||
branch_select = memnew(OptionButton);
|
branch_select = memnew(OptionButton);
|
||||||
branch_select->set_tooltip_text(TTR("Branches"));
|
branch_select->set_tooltip_text(TTR("Branches"));
|
||||||
branch_select->set_h_size_flags(Control::SIZE_EXPAND_FILL);
|
branch_select->set_h_size_flags(Control::SIZE_EXPAND_FILL);
|
||||||
|
branch_select->set_clip_text(true);
|
||||||
branch_select->connect(SceneStringName(item_selected), callable_mp(this, &VersionControlEditorPlugin::_branch_item_selected));
|
branch_select->connect(SceneStringName(item_selected), callable_mp(this, &VersionControlEditorPlugin::_branch_item_selected));
|
||||||
branch_select->connect(SceneStringName(pressed), callable_mp(this, &VersionControlEditorPlugin::_refresh_branch_list));
|
branch_select->connect(SceneStringName(pressed), callable_mp(this, &VersionControlEditorPlugin::_refresh_branch_list));
|
||||||
menu_bar->add_child(branch_select);
|
menu_bar->add_child(branch_select);
|
||||||
@@ -1353,6 +1355,7 @@ VersionControlEditorPlugin::VersionControlEditorPlugin() {
|
|||||||
remote_select = memnew(OptionButton);
|
remote_select = memnew(OptionButton);
|
||||||
remote_select->set_tooltip_text(TTR("Remotes"));
|
remote_select->set_tooltip_text(TTR("Remotes"));
|
||||||
remote_select->set_h_size_flags(Control::SIZE_EXPAND_FILL);
|
remote_select->set_h_size_flags(Control::SIZE_EXPAND_FILL);
|
||||||
|
remote_select->set_clip_text(true);
|
||||||
remote_select->connect(SceneStringName(item_selected), callable_mp(this, &VersionControlEditorPlugin::_remote_selected));
|
remote_select->connect(SceneStringName(item_selected), callable_mp(this, &VersionControlEditorPlugin::_remote_selected));
|
||||||
remote_select->connect(SceneStringName(pressed), callable_mp(this, &VersionControlEditorPlugin::_refresh_remote_list));
|
remote_select->connect(SceneStringName(pressed), callable_mp(this, &VersionControlEditorPlugin::_refresh_remote_list));
|
||||||
menu_bar->add_child(remote_select);
|
menu_bar->add_child(remote_select);
|
||||||
|
|||||||
Reference in New Issue
Block a user