diff options
author | Juan Linietsky <juan@godotengine.org> | 2018-02-25 12:06:30 -0300 |
---|---|---|
committer | Juan Linietsky <juan@godotengine.org> | 2018-02-25 12:07:13 -0300 |
commit | 125fc8cc4432d28e63da76c3a2aff655b1a7cc6b (patch) | |
tree | f25f62ae4acc2e7a1512d9ed101c791e5f2ca50d /editor/plugins/polygon_2d_editor_plugin.h | |
parent | eec9261a75699723f6e4b722910e5bb762b736db (diff) |
Add a split editor to polygon 2D UV editor, moving an inch closer to adding support for in the future
Diffstat (limited to 'editor/plugins/polygon_2d_editor_plugin.h')
-rw-r--r-- | editor/plugins/polygon_2d_editor_plugin.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/editor/plugins/polygon_2d_editor_plugin.h b/editor/plugins/polygon_2d_editor_plugin.h index 2ea2082052..8631ffb9a7 100644 --- a/editor/plugins/polygon_2d_editor_plugin.h +++ b/editor/plugins/polygon_2d_editor_plugin.h @@ -55,17 +55,19 @@ class Polygon2DEditor : public AbstractPolygon2DEditor { UV_MODE_MOVE, UV_MODE_ROTATE, UV_MODE_SCALE, + UV_MODE_ADD_SPLIT, + UV_MODE_REMOVE_SPLIT, UV_MODE_MAX }; - ToolButton *uv_edit_mode[2]; + ToolButton *uv_edit_mode[3]; Ref<ButtonGroup> uv_edit_group; Polygon2D *node; UVMode uv_mode; AcceptDialog *uv_edit; - ToolButton *uv_button[5]; + ToolButton *uv_button[UV_MODE_MAX]; ToolButton *b_snap_enable; ToolButton *b_snap_grid; Control *uv_edit_draw; @@ -81,10 +83,13 @@ class Polygon2DEditor : public AbstractPolygon2DEditor { PoolVector<Vector2> uv_prev; PoolVector<Vector2> uv_create_uv_prev; PoolVector<Vector2> uv_create_poly_prev; + PoolVector<int> splits_prev; + Vector2 uv_create_to; int uv_drag_index; bool uv_drag; bool uv_create; + bool split_create; UVMode uv_move_current; Vector2 uv_drag_from; bool updating_uv_scroll; |