mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2025-01-23 17:47:17 +01:00
Rearranged ViewportNavigationControl.
This commit is contained in:
parent
37961b1990
commit
94a9792d02
@ -872,14 +872,9 @@ public:
|
|||||||
class ViewportNavigationControl : public Control {
|
class ViewportNavigationControl : public Control {
|
||||||
GDCLASS(ViewportNavigationControl, Control);
|
GDCLASS(ViewportNavigationControl, Control);
|
||||||
|
|
||||||
SpatialEditorViewport *viewport = nullptr;
|
public:
|
||||||
Vector2i focused_mouse_start;
|
void set_navigation_mode(SpatialEditorViewport::NavigationMode p_nav_mode);
|
||||||
Vector2 focused_pos;
|
void set_viewport(SpatialEditorViewport *p_viewport);
|
||||||
bool hovered = false;
|
|
||||||
int focused_index = -1;
|
|
||||||
SpatialEditorViewport::NavigationMode nav_mode = SpatialEditorViewport::NavigationMode::NAVIGATION_NONE;
|
|
||||||
|
|
||||||
const float AXIS_CIRCLE_RADIUS = 30.0f * EDSCALE;
|
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
static void _bind_methods();
|
static void _bind_methods();
|
||||||
@ -892,9 +887,15 @@ protected:
|
|||||||
void _process_drag(int p_index, Vector2 p_position, Vector2 p_relative_position);
|
void _process_drag(int p_index, Vector2 p_position, Vector2 p_relative_position);
|
||||||
void _update_navigation();
|
void _update_navigation();
|
||||||
|
|
||||||
public:
|
private:
|
||||||
void set_navigation_mode(SpatialEditorViewport::NavigationMode p_nav_mode);
|
SpatialEditorViewport *viewport = nullptr;
|
||||||
void set_viewport(SpatialEditorViewport *p_viewport);
|
Vector2i focused_mouse_start;
|
||||||
|
Vector2 focused_pos;
|
||||||
|
bool hovered = false;
|
||||||
|
int focused_index = -1;
|
||||||
|
SpatialEditorViewport::NavigationMode nav_mode = SpatialEditorViewport::NavigationMode::NAVIGATION_NONE;
|
||||||
|
|
||||||
|
const float AXIS_CIRCLE_RADIUS = 30.0f * EDSCALE;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user