diff options
author | Natrim <maly@kinet.cz> | 2018-08-17 11:47:29 +0200 |
---|---|---|
committer | Natrim <maly@kinet.cz> | 2018-08-17 12:25:48 +0200 |
commit | 6ad0f4ebe8c429eb5e4e8ff52aa0c416574d767e (patch) | |
tree | da116567cd79dda4d71bcdff1b879d49926095b7 /editor/plugins | |
parent | 985ed5e55abe880025fd3f0cfa484a23d3a0ca32 (diff) |
Particles2D: fix editing Visibility Rect from inspector
+ renamed generate_aabb to generate_visibility_rect to prevent future confusions
Diffstat (limited to 'editor/plugins')
-rw-r--r-- | editor/plugins/particles_2d_editor_plugin.cpp | 16 | ||||
-rw-r--r-- | editor/plugins/particles_2d_editor_plugin.h | 2 |
2 files changed, 8 insertions, 10 deletions
diff --git a/editor/plugins/particles_2d_editor_plugin.cpp b/editor/plugins/particles_2d_editor_plugin.cpp index b50e0dfe88..ae5d510502 100644 --- a/editor/plugins/particles_2d_editor_plugin.cpp +++ b/editor/plugins/particles_2d_editor_plugin.cpp @@ -58,8 +58,6 @@ void Particles2DEditorPlugin::make_visible(bool p_visible) { void Particles2DEditorPlugin::_file_selected(const String &p_file) { - print_line("file: " + p_file); - source_emission_file = p_file; emission_mask->popup_centered_minsize(); } @@ -73,7 +71,7 @@ void Particles2DEditorPlugin::_menu_callback(int p_idx) { generate_seconds->set_value(1.0); else generate_seconds->set_value(trunc(gen_time) + 1.0); - generate_aabb->popup_centered_minsize(); + generate_visibility_rect->popup_centered_minsize(); } break; case MENU_LOAD_EMISSION_MASK: { @@ -93,7 +91,7 @@ void Particles2DEditorPlugin::_generate_visibility_rect() { float running = 0.0; - EditorProgress ep("gen_aabb", TTR("Generating AABB"), int(time)); + EditorProgress ep("gen_vrect", TTR("Generating Visibility Rect"), int(time)); bool was_emitting = particles->is_emitting(); if (!was_emitting) { @@ -376,19 +374,19 @@ Particles2DEditorPlugin::Particles2DEditorPlugin(EditorNode *p_node) { epoints->set_value(512); file->get_vbox()->add_margin_child(TTR("Generated Point Count:"), epoints); - generate_aabb = memnew(ConfirmationDialog); - generate_aabb->set_title(TTR("Generate Visibility Rect")); + generate_visibility_rect = memnew(ConfirmationDialog); + generate_visibility_rect->set_title(TTR("Generate Visibility Rect")); VBoxContainer *genvb = memnew(VBoxContainer); - generate_aabb->add_child(genvb); + generate_visibility_rect->add_child(genvb); generate_seconds = memnew(SpinBox); genvb->add_margin_child(TTR("Generation Time (sec):"), generate_seconds); generate_seconds->set_min(0.1); generate_seconds->set_max(25); generate_seconds->set_value(2); - toolbar->add_child(generate_aabb); + toolbar->add_child(generate_visibility_rect); - generate_aabb->connect("confirmed", this, "_generate_visibility_rect"); + generate_visibility_rect->connect("confirmed", this, "_generate_visibility_rect"); emission_mask = memnew(ConfirmationDialog); emission_mask->set_title(TTR("Generate Visibility Rect")); diff --git a/editor/plugins/particles_2d_editor_plugin.h b/editor/plugins/particles_2d_editor_plugin.h index addf65789c..2b6123141b 100644 --- a/editor/plugins/particles_2d_editor_plugin.h +++ b/editor/plugins/particles_2d_editor_plugin.h @@ -66,7 +66,7 @@ class Particles2DEditorPlugin : public EditorPlugin { SpinBox *epoints; - ConfirmationDialog *generate_aabb; + ConfirmationDialog *generate_visibility_rect; SpinBox *generate_seconds; ConfirmationDialog *emission_mask; |