diff options
author | Nao Pross <naopross@thearcway.org> | 2019-01-25 01:11:57 +0100 |
---|---|---|
committer | Nao Pross <naopross@thearcway.org> | 2019-01-25 01:11:57 +0100 |
commit | bcd14a356cafe58808b4c2a14782ebb194c6abc5 (patch) | |
tree | 3bc95288b0a0172bb447ccf218fb59821f22501a /engine/include/component.hpp | |
parent | Delete bin and test/makefile update .gitignore (diff) | |
download | flatland-bcd14a356cafe58808b4c2a14782ebb194c6abc5.tar.gz flatland-bcd14a356cafe58808b4c2a14782ebb194c6abc5.zip |
Rename everything under engine/ to remove `flat' and be `.hpp'
Diffstat (limited to 'engine/include/component.hpp')
-rw-r--r-- | engine/include/component.hpp | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/engine/include/component.hpp b/engine/include/component.hpp new file mode 100644 index 0000000..4ad99c8 --- /dev/null +++ b/engine/include/component.hpp @@ -0,0 +1,32 @@ +#ifndef __FLAT_COMPONENT_H__ +#define __FLAT_COMPONENT_H__ + +#include "core/object.hpp" +#include "core/labelled.hpp" +#include <string> + +namespace flat { + +class component : virtual public core::object, virtual public core::labelled +{ + + component * m_parent; + +public: + + /* Zero means attach to main window layer */ + /* Send a 'created' signal in component reserved channel */ + component(component *parent = 0, const std::string& id = ""); + + /* Send a 'deleted' signal in component reserved channel */ + virtual ~component(); + + void set_parent(component*); + component * parent(); + + virtual void render() = 0; +}; + +} + +#endif |