diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2024-01-29 13:18:09 +0100 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2024-01-29 13:18:09 +0100 |
commit | fa48a51183567934984b381ad8ec281cb24d66ba (patch) | |
tree | f4737d9d29666e6e531a0fd163c49420383484f5 /editor | |
parent | e59e58a68afd60d0fa63e61751bd6d30575f3bb3 (diff) | |
parent | 15369fdb1d692e1515dd888dfbae275074be63be (diff) | |
download | redot-engine-fa48a51183567934984b381ad8ec281cb24d66ba.tar.gz |
Merge pull request #87688 from AThousandShips/what_is_this
Remove unnecessary `this->` expressions
Diffstat (limited to 'editor')
-rw-r--r-- | editor/editor_audio_buses.cpp | 2 | ||||
-rw-r--r-- | editor/editor_help.cpp | 18 | ||||
-rw-r--r-- | editor/editor_inspector.cpp | 4 | ||||
-rw-r--r-- | editor/editor_node.cpp | 2 | ||||
-rw-r--r-- | editor/export/editor_export_platform.cpp | 2 | ||||
-rw-r--r-- | editor/plugins/script_text_editor.cpp | 2 | ||||
-rw-r--r-- | editor/plugins/sprite_2d_editor_plugin.cpp | 8 | ||||
-rw-r--r-- | editor/plugins/text_editor.cpp | 2 | ||||
-rw-r--r-- | editor/project_manager.cpp | 2 |
9 files changed, 21 insertions, 21 deletions
diff --git a/editor/editor_audio_buses.cpp b/editor/editor_audio_buses.cpp index 61a4b341b9..5127dd43d8 100644 --- a/editor/editor_audio_buses.cpp +++ b/editor/editor_audio_buses.cpp @@ -328,7 +328,7 @@ void EditorAudioBus::_volume_changed(float p_normalized) { updating_bus = true; - const float p_db = this->_normalized_volume_to_scaled_db(p_normalized); + const float p_db = _normalized_volume_to_scaled_db(p_normalized); if (Input::get_singleton()->is_key_pressed(Key::CMD_OR_CTRL)) { // Snap the value when holding Ctrl for easier editing. diff --git a/editor/editor_help.cpp b/editor/editor_help.cpp index dd0bbccbee..fc4c8ea4b7 100644 --- a/editor/editor_help.cpp +++ b/editor/editor_help.cpp @@ -220,31 +220,31 @@ void EditorHelp::_class_desc_select(const String &p_select) { if (tag == "method") { topic = "class_method"; - table = &this->method_line; + table = &method_line; } else if (tag == "constructor") { topic = "class_method"; - table = &this->method_line; + table = &method_line; } else if (tag == "operator") { topic = "class_method"; - table = &this->method_line; + table = &method_line; } else if (tag == "member") { topic = "class_property"; - table = &this->property_line; + table = &property_line; } else if (tag == "enum") { topic = "class_enum"; - table = &this->enum_line; + table = &enum_line; } else if (tag == "signal") { topic = "class_signal"; - table = &this->signal_line; + table = &signal_line; } else if (tag == "constant") { topic = "class_constant"; - table = &this->constant_line; + table = &constant_line; } else if (tag == "annotation") { topic = "class_annotation"; - table = &this->annotation_line; + table = &annotation_line; } else if (tag == "theme_item") { topic = "theme_item"; - table = &this->theme_property_line; + table = &theme_property_line; } else { return; } diff --git a/editor/editor_inspector.cpp b/editor/editor_inspector.cpp index bfadc48b33..0711bbe84e 100644 --- a/editor/editor_inspector.cpp +++ b/editor/editor_inspector.cpp @@ -3789,13 +3789,13 @@ void EditorInspector::_property_changed(const String &p_path, const Variant &p_v // The "changing" variable must be true for properties that trigger events as typing occurs, // like "text_changed" signal. E.g. text property of Label, Button, RichTextLabel, etc. if (p_changing) { - this->changing++; + changing++; } _edit_set(p_path, p_value, p_update_all, p_name); if (p_changing) { - this->changing--; + changing--; } if (restart_request_props.has(p_path)) { diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index 23d5704048..a51717bedd 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -2335,7 +2335,7 @@ void EditorNode::_edit_current(bool p_skip_foreign) { } bool inspector_only = editor_history.is_current_inspector_only(); - this->current = current_obj; + current = current_obj; if (!current_obj) { SceneTreeDock::get_singleton()->set_selected(nullptr); diff --git a/editor/export/editor_export_platform.cpp b/editor/export/editor_export_platform.cpp index ee25893a30..440089022b 100644 --- a/editor/export/editor_export_platform.cpp +++ b/editor/export/editor_export_platform.cpp @@ -1210,7 +1210,7 @@ Error EditorExportPlatform::export_project_files(const Ref<EditorExportPreset> & } if (remap_features.size() > 1) { - this->resolve_platform_feature_priorities(p_preset, remap_features); + resolve_platform_feature_priorities(p_preset, remap_features); } err = OK; diff --git a/editor/plugins/script_text_editor.cpp b/editor/plugins/script_text_editor.cpp index 370144a427..d8fb55ca54 100644 --- a/editor/plugins/script_text_editor.cpp +++ b/editor/plugins/script_text_editor.cpp @@ -2508,5 +2508,5 @@ void ScriptTextEditor::register_editor() { } void ScriptTextEditor::validate() { - this->code_editor->validate_script(); + code_editor->validate_script(); } diff --git a/editor/plugins/sprite_2d_editor_plugin.cpp b/editor/plugins/sprite_2d_editor_plugin.cpp index c1e7070451..3e98f3d64f 100644 --- a/editor/plugins/sprite_2d_editor_plugin.cpp +++ b/editor/plugins/sprite_2d_editor_plugin.cpp @@ -416,7 +416,7 @@ void Sprite2DEditor::_create_collision_polygon_2d_node() { ur->create_action(TTR("Create CollisionPolygon2D Sibling")); ur->add_do_method(this, "_add_as_sibling_or_child", node, collision_polygon_2d_instance); ur->add_do_reference(collision_polygon_2d_instance); - ur->add_undo_method(node != this->get_tree()->get_edited_scene_root() ? node->get_parent() : this->get_tree()->get_edited_scene_root(), "remove_child", collision_polygon_2d_instance); + ur->add_undo_method(node != get_tree()->get_edited_scene_root() ? node->get_parent() : get_tree()->get_edited_scene_root(), "remove_child", collision_polygon_2d_instance); ur->commit_action(); } } @@ -449,21 +449,21 @@ void Sprite2DEditor::_create_light_occluder_2d_node() { ur->create_action(TTR("Create LightOccluder2D Sibling")); ur->add_do_method(this, "_add_as_sibling_or_child", node, light_occluder_2d_instance); ur->add_do_reference(light_occluder_2d_instance); - ur->add_undo_method(node != this->get_tree()->get_edited_scene_root() ? node->get_parent() : this->get_tree()->get_edited_scene_root(), "remove_child", light_occluder_2d_instance); + ur->add_undo_method(node != get_tree()->get_edited_scene_root() ? node->get_parent() : get_tree()->get_edited_scene_root(), "remove_child", light_occluder_2d_instance); ur->commit_action(); } } void Sprite2DEditor::_add_as_sibling_or_child(Node *p_own_node, Node *p_new_node) { // Can't make sibling if own node is scene root - if (p_own_node != this->get_tree()->get_edited_scene_root()) { + if (p_own_node != get_tree()->get_edited_scene_root()) { p_own_node->get_parent()->add_child(p_new_node, true); Object::cast_to<Node2D>(p_new_node)->set_transform(Object::cast_to<Node2D>(p_own_node)->get_transform()); } else { p_own_node->add_child(p_new_node, true); } - p_new_node->set_owner(this->get_tree()->get_edited_scene_root()); + p_new_node->set_owner(get_tree()->get_edited_scene_root()); } void Sprite2DEditor::_debug_uv_input(const Ref<InputEvent> &p_input) { diff --git a/editor/plugins/text_editor.cpp b/editor/plugins/text_editor.cpp index 3fdb0388f2..a2364278b6 100644 --- a/editor/plugins/text_editor.cpp +++ b/editor/plugins/text_editor.cpp @@ -712,5 +712,5 @@ TextEditor::~TextEditor() { } void TextEditor::validate() { - this->code_editor->validate_script(); + code_editor->validate_script(); } diff --git a/editor/project_manager.cpp b/editor/project_manager.cpp index fff7b89c01..d18e5a237f 100644 --- a/editor/project_manager.cpp +++ b/editor/project_manager.cpp @@ -843,7 +843,7 @@ void ProjectManager::shortcut_input(const Ref<InputEvent> &p_ev) { } break; case Key::F: { if (k->is_command_or_control_pressed()) { - this->search_box->grab_focus(); + search_box->grab_focus(); } else { keycode_handled = false; } |