diff options
author | Juan Linietsky <reduzio@gmail.com> | 2016-10-05 01:26:35 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2016-10-05 01:26:35 -0300 |
commit | cf5778e51a883936ffc896231da8259e5ebabc0a (patch) | |
tree | 286f7eb7956a5c2c275276bbc9e3db5e3ff0730f /scene/gui/viewport_container.h | |
parent | a6e9dc615346f44b68b418483dd218d11ba4a674 (diff) | |
download | redot-engine-cf5778e51a883936ffc896231da8259e5ebabc0a.tar.gz |
-Added ViewportContainer, this is the only way to make viewports show up in GUI now
-2D editing now seems to work
-Added some functions and refactoring to Viewport
Diffstat (limited to 'scene/gui/viewport_container.h')
-rw-r--r-- | scene/gui/viewport_container.h | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/scene/gui/viewport_container.h b/scene/gui/viewport_container.h new file mode 100644 index 0000000000..cfc58f7d6e --- /dev/null +++ b/scene/gui/viewport_container.h @@ -0,0 +1,25 @@ +#ifndef VIEWPORTCONTAINER_H +#define VIEWPORTCONTAINER_H + +#include "scene/gui/container.h" + +class ViewportContainer : public Container { + + OBJ_TYPE( ViewportContainer, Container ); + + bool stretch; +protected: + + void _notification(int p_what); + static void _bind_methods(); +public: + + void set_stretch(bool p_enable); + bool is_stretch_enabled() const; + + virtual Size2 get_minimum_size() const; + + ViewportContainer(); +}; + +#endif // VIEWPORTCONTAINER_H |