diff --git a/core/globals.cpp b/core/globals.cpp index 38e88e43e23..8f371bb7c11 100644 --- a/core/globals.cpp +++ b/core/globals.cpp @@ -137,7 +137,7 @@ bool Globals::_set(const StringName& p_name, const Variant& p_value) { props[p_name].order=last_order++; } } else { - props[p_name]=VariantContainer(p_value,last_order++ + registering_order?0:NO_ORDER_BASE); + props[p_name]=VariantContainer(p_value,last_order++ + (registering_order?0:NO_ORDER_BASE)); } } diff --git a/scene/gui/rich_text_label.cpp b/scene/gui/rich_text_label.cpp index b65ff156f2e..eaff08e1d1c 100644 --- a/scene/gui/rich_text_label.cpp +++ b/scene/gui/rich_text_label.cpp @@ -86,7 +86,7 @@ RichTextLabel::Item *RichTextLabel::_get_next_item(Item* p_item,bool p_free) { void RichTextLabel::_process_line(ItemFrame *p_frame,const Vector2& p_ofs,int &y, int p_width, int p_line, ProcessMode p_mode,const Ref &p_base_font,const Color &p_base_color,const Point2i& p_click_pos,Item **r_click_item,int *r_click_char,bool *r_outside,int p_char_count) { - print_line("BEGIN"); + RID ci; if (r_outside) *r_outside=false; diff --git a/tools/editor/project_settings.cpp b/tools/editor/project_settings.cpp index 132ae5f0da0..301ae2ec141 100644 --- a/tools/editor/project_settings.cpp +++ b/tools/editor/project_settings.cpp @@ -930,11 +930,14 @@ void ProjectSettings::_autoload_delete(Object *p_item,int p_column, int p_button String swap_name= "autoload/"+swap->get_text(0); + int order = Globals::get_singleton()->get_order(name); + int swap_order = Globals::get_singleton()->get_order(swap_name); + undo_redo->create_action("Move Autoload"); - undo_redo->add_do_method(Globals::get_singleton(),"set_order",swap_name,Globals::get_singleton()->get_order(name)); - undo_redo->add_do_method(Globals::get_singleton(),"set_order",name,Globals::get_singleton()->get_order(swap_name)); - undo_redo->add_undo_method(Globals::get_singleton(),"set_order",swap_name,Globals::get_singleton()->get_order(swap_name)); - undo_redo->add_undo_method(Globals::get_singleton(),"set_order",name,Globals::get_singleton()->get_order(name)); + undo_redo->add_do_method(Globals::get_singleton(),"set_order",swap_name,order); + undo_redo->add_do_method(Globals::get_singleton(),"set_order",name,swap_order); + undo_redo->add_undo_method(Globals::get_singleton(),"set_order",swap_name,swap_order); + undo_redo->add_undo_method(Globals::get_singleton(),"set_order",name,order); undo_redo->add_do_method(this,"_update_autoload"); undo_redo->add_undo_method(this,"_update_autoload"); undo_redo->add_do_method(this,"_settings_changed");