mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2025-02-13 19:30:08 +01:00
Renamed MDIEdUVEditor to MDIEdUVPreviewer.
This commit is contained in:
parent
bb4504d2f7
commit
4e025703f8
@ -31,7 +31,7 @@ if 'TOOLS_ENABLED' in env["CPPDEFINES"]:
|
|||||||
module_env.add_source_files(env.modules_sources,"editor/utilities/mdr_ed_mesh_outline.cpp")
|
module_env.add_source_files(env.modules_sources,"editor/utilities/mdr_ed_mesh_outline.cpp")
|
||||||
module_env.add_source_files(env.modules_sources,"editor/utilities/mdr_ed_mesh_utils.cpp")
|
module_env.add_source_files(env.modules_sources,"editor/utilities/mdr_ed_mesh_utils.cpp")
|
||||||
|
|
||||||
module_env.add_source_files(env.modules_sources,"editor/uv_editor/mdi_ed_uv_editor.cpp")
|
module_env.add_source_files(env.modules_sources,"editor/uv_editor/mdi_ed_uv_previewer.cpp")
|
||||||
module_env.add_source_files(env.modules_sources,"editor/uv_editor/mdr_uv_rect_editor.cpp")
|
module_env.add_source_files(env.modules_sources,"editor/uv_editor/mdr_uv_rect_editor.cpp")
|
||||||
module_env.add_source_files(env.modules_sources,"editor/uv_editor/mdr_uv_rect_view_node.cpp")
|
module_env.add_source_files(env.modules_sources,"editor/uv_editor/mdr_uv_rect_view_node.cpp")
|
||||||
module_env.add_source_files(env.modules_sources,"editor/uv_editor/mdr_uv_rect_view_popup.cpp")
|
module_env.add_source_files(env.modules_sources,"editor/uv_editor/mdr_uv_rect_view_popup.cpp")
|
||||||
|
@ -20,13 +20,13 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|||||||
SOFTWARE.
|
SOFTWARE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "mdi_ed_uv_editor.h"
|
#include "mdi_ed_uv_previewer.h"
|
||||||
|
|
||||||
#include "../../mesh_data_resource.h"
|
#include "../../mesh_data_resource.h"
|
||||||
#include "../../nodes/mesh_data_instance.h"
|
#include "../../nodes/mesh_data_instance.h"
|
||||||
#include "scene/resources/texture.h"
|
#include "scene/resources/texture.h"
|
||||||
|
|
||||||
void MDIEdUVEditor::set_mesh_data_resource(Ref<MeshDataResource> a) {
|
void MDIEdUVPreviewer::set_mesh_data_resource(Ref<MeshDataResource> a) {
|
||||||
if (mesh_data_resource.is_valid()) {
|
if (mesh_data_resource.is_valid()) {
|
||||||
mesh_data_resource->disconnect("changed", this, "on_mdr_changed");
|
mesh_data_resource->disconnect("changed", this, "on_mdr_changed");
|
||||||
}
|
}
|
||||||
@ -40,7 +40,7 @@ void MDIEdUVEditor::set_mesh_data_resource(Ref<MeshDataResource> a) {
|
|||||||
update();
|
update();
|
||||||
}
|
}
|
||||||
|
|
||||||
void MDIEdUVEditor::set_mesh_data_instance(MeshDataInstance *a) {
|
void MDIEdUVPreviewer::set_mesh_data_instance(MeshDataInstance *a) {
|
||||||
if (!a) {
|
if (!a) {
|
||||||
background_texture.unref();
|
background_texture.unref();
|
||||||
return;
|
return;
|
||||||
@ -49,11 +49,11 @@ void MDIEdUVEditor::set_mesh_data_instance(MeshDataInstance *a) {
|
|||||||
background_texture = a->get_texture();
|
background_texture = a->get_texture();
|
||||||
}
|
}
|
||||||
|
|
||||||
void MDIEdUVEditor::on_mdr_changed() {
|
void MDIEdUVPreviewer::on_mdr_changed() {
|
||||||
update();
|
update();
|
||||||
}
|
}
|
||||||
|
|
||||||
void MDIEdUVEditor::_draw() {
|
void MDIEdUVPreviewer::_draw() {
|
||||||
if (background_texture.is_valid()) {
|
if (background_texture.is_valid()) {
|
||||||
draw_texture_rect_region(background_texture, Rect2(Vector2(), get_size()), Rect2(Vector2(), background_texture->get_size()));
|
draw_texture_rect_region(background_texture, Rect2(Vector2(), get_size()), Rect2(Vector2(), background_texture->get_size()));
|
||||||
}
|
}
|
||||||
@ -102,11 +102,11 @@ void MDIEdUVEditor::_draw() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
MDIEdUVEditor::MDIEdUVEditor() {
|
MDIEdUVPreviewer::MDIEdUVPreviewer() {
|
||||||
}
|
}
|
||||||
|
|
||||||
MDIEdUVEditor::~MDIEdUVEditor() {
|
MDIEdUVPreviewer::~MDIEdUVPreviewer() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void MDIEdUVEditor::_bind_methods() {
|
void MDIEdUVPreviewer::_bind_methods() {
|
||||||
}
|
}
|
@ -1,5 +1,5 @@
|
|||||||
#ifndef MDI_ED_UV_EDITOR_H
|
#ifndef MDI_ED_UV_PREVIEWER_H
|
||||||
#define MDI_ED_UV_EDITOR_H
|
#define MDI_ED_UV_PREVIEWER_H
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Copyright (c) 2019-2022 Péter Magyar
|
Copyright (c) 2019-2022 Péter Magyar
|
||||||
@ -31,8 +31,8 @@ class MeshDataResource;
|
|||||||
class MeshDataInstance;
|
class MeshDataInstance;
|
||||||
class Texture;
|
class Texture;
|
||||||
|
|
||||||
class MDIEdUVEditor : public Control {
|
class MDIEdUVPreviewer : public Control {
|
||||||
GDCLASS(MDIEdUVEditor, Control);
|
GDCLASS(MDIEdUVPreviewer, Control);
|
||||||
|
|
||||||
public:
|
public:
|
||||||
void set_mesh_data_resource(Ref<MeshDataResource> a);
|
void set_mesh_data_resource(Ref<MeshDataResource> a);
|
||||||
@ -40,8 +40,8 @@ public:
|
|||||||
void on_mdr_changed();
|
void on_mdr_changed();
|
||||||
void _draw();
|
void _draw();
|
||||||
|
|
||||||
MDIEdUVEditor();
|
MDIEdUVPreviewer();
|
||||||
~MDIEdUVEditor();
|
~MDIEdUVPreviewer();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
static void _bind_methods();
|
static void _bind_methods();
|
Loading…
Reference in New Issue
Block a user