diff options
Diffstat (limited to 'editor')
-rw-r--r-- | editor/plugins/spatial_editor_plugin.cpp | 4 | ||||
-rw-r--r-- | editor/project_manager.cpp | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/editor/plugins/spatial_editor_plugin.cpp b/editor/plugins/spatial_editor_plugin.cpp index a549f09cb1..13fdb7ac9d 100644 --- a/editor/plugins/spatial_editor_plugin.cpp +++ b/editor/plugins/spatial_editor_plugin.cpp @@ -285,11 +285,11 @@ ObjectID SpatialEditorViewport::_select_ray(const Point2 &p_pos, bool p_append, Node *subscene_candidate = spat; - while (subscene_candidate->get_owner() != editor->get_edited_scene()) + while ((subscene_candidate->get_owner() != NULL) && (subscene_candidate->get_owner() != editor->get_edited_scene())) subscene_candidate = subscene_candidate->get_owner(); spat = subscene_candidate->cast_to<Spatial>(); - if (spat && (spat->get_filename() != "")) + if (spat && (spat->get_filename() != "") && (subscene_candidate->get_owner() != NULL)) subscenes.push_back(spat); continue; diff --git a/editor/project_manager.cpp b/editor/project_manager.cpp index b77544befa..dc0c888eea 100644 --- a/editor/project_manager.cpp +++ b/editor/project_manager.cpp @@ -848,6 +848,7 @@ void ProjectManager::_load_recent_projects() { VBoxContainer *vb = memnew(VBoxContainer); vb->set_name("project"); + vb->set_h_size_flags(SIZE_EXPAND_FILL); hb->add_child(vb); Control *ec = memnew(Control); ec->set_custom_minimum_size(Size2(0, 1)); @@ -855,12 +856,14 @@ void ProjectManager::_load_recent_projects() { Label *title = memnew(Label(project_name)); title->add_font_override("font", gui_base->get_font("large", "Fonts")); title->add_color_override("font_color", font_color); + title->set_clip_text(true); vb->add_child(title); Label *fpath = memnew(Label(path)); fpath->set_name("path"); vb->add_child(fpath); fpath->set_modulate(Color(1, 1, 1, 0.5)); fpath->add_color_override("font_color", font_color); + fpath->set_clip_text(true); scroll_childs->add_child(hb); } |