mirror of
https://github.com/godotengine/godot.git
synced 2024-12-27 11:24:59 +08:00
Merge pull request #89434 from jsjtxietian/center-view
Fix center view button appears outside the GenericTilePolygonEditor
This commit is contained in:
commit
734bd3c8c4
@ -946,8 +946,10 @@ GenericTilePolygonEditor::GenericTilePolygonEditor() {
|
||||
|
||||
button_center_view = memnew(Button);
|
||||
button_center_view->set_anchors_and_offsets_preset(Control::PRESET_TOP_RIGHT, Control::PRESET_MODE_MINSIZE, 5);
|
||||
button_center_view->set_grow_direction_preset(Control::PRESET_TOP_RIGHT);
|
||||
button_center_view->connect("pressed", callable_mp(this, &GenericTilePolygonEditor::_center_view));
|
||||
button_center_view->set_theme_type_variation("FlatButton");
|
||||
button_center_view->set_tooltip_text(TTR("Center View"));
|
||||
button_center_view->set_disabled(true);
|
||||
root->add_child(button_center_view);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user