diff options
author | Juan Linietsky <reduzio@gmail.com> | 2020-03-26 18:49:16 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2020-03-27 14:54:04 +0100 |
commit | eaae4b6408361eb34363adcb22a08046f43147f4 (patch) | |
tree | 4baf4cd8758696d260bef2cb149e27bf3135a284 /editor/plugins/path_editor_plugin.h | |
parent | 9a7dbc2acafdd04ff0fe09bc5f4838b4920348a8 (diff) |
Renamed 2D and 3D nodes to make their types explicit
Fixes #30736.
Diffstat (limited to 'editor/plugins/path_editor_plugin.h')
-rw-r--r-- | editor/plugins/path_editor_plugin.h | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/editor/plugins/path_editor_plugin.h b/editor/plugins/path_editor_plugin.h index 8ff83911f8..0a27e1068e 100644 --- a/editor/plugins/path_editor_plugin.h +++ b/editor/plugins/path_editor_plugin.h @@ -32,13 +32,13 @@ #define PATH_EDITOR_PLUGIN_H #include "editor/spatial_editor_gizmos.h" -#include "scene/3d/path.h" +#include "scene/3d/path_3d.h" -class PathSpatialGizmo : public EditorSpatialGizmo { +class PathNode3DGizmo : public EditorNode3DGizmo { - GDCLASS(PathSpatialGizmo, EditorSpatialGizmo); + GDCLASS(PathNode3DGizmo, EditorNode3DGizmo); - Path *path; + Path3D *path; mutable Vector3 original; mutable float orig_in_length; mutable float orig_out_length; @@ -46,24 +46,24 @@ class PathSpatialGizmo : public EditorSpatialGizmo { public: virtual String get_handle_name(int p_idx) const; virtual Variant get_handle_value(int p_idx); - virtual void set_handle(int p_idx, Camera *p_camera, const Point2 &p_point); + virtual void set_handle(int p_idx, Camera3D *p_camera, const Point2 &p_point); virtual void commit_handle(int p_idx, const Variant &p_restore, bool p_cancel = false); virtual void redraw(); - PathSpatialGizmo(Path *p_path = NULL); + PathNode3DGizmo(Path3D *p_path = NULL); }; -class PathSpatialGizmoPlugin : public EditorSpatialGizmoPlugin { +class PathNode3DGizmoPlugin : public EditorNode3DGizmoPlugin { - GDCLASS(PathSpatialGizmoPlugin, EditorSpatialGizmoPlugin); + GDCLASS(PathNode3DGizmoPlugin, EditorNode3DGizmoPlugin); protected: - Ref<EditorSpatialGizmo> create_gizmo(Spatial *p_spatial); + Ref<EditorNode3DGizmo> create_gizmo(Node3D *p_spatial); public: String get_name() const; int get_priority() const; - PathSpatialGizmoPlugin(); + PathNode3DGizmoPlugin(); }; class PathEditorPlugin : public EditorPlugin { @@ -79,7 +79,7 @@ class PathEditorPlugin : public EditorPlugin { EditorNode *editor; - Path *path; + Path3D *path; void _mode_changed(int p_idx); void _close_curve(); @@ -98,13 +98,13 @@ protected: static void _bind_methods(); public: - Path *get_edited_path() { return path; } + Path3D *get_edited_path() { return path; } static PathEditorPlugin *singleton; - virtual bool forward_spatial_gui_input(Camera *p_camera, const Ref<InputEvent> &p_event); + virtual bool forward_spatial_gui_input(Camera3D *p_camera, const Ref<InputEvent> &p_event); //virtual bool forward_gui_input(const InputEvent& p_event) { return collision_polygon_editor->forward_gui_input(p_event); } - //virtual Ref<SpatialEditorGizmo> create_spatial_gizmo(Spatial *p_spatial); + //virtual Ref<Node3DEditorGizmo> create_spatial_gizmo(Spatial *p_spatial); virtual String get_name() const { return "Path"; } bool has_main_screen() const { return false; } virtual void edit(Object *p_object); |