diff --git a/src/guiengine/screen.hpp b/src/guiengine/screen.hpp index a5e0a3ece..51d89f0fe 100644 --- a/src/guiengine/screen.hpp +++ b/src/guiengine/screen.hpp @@ -69,14 +69,6 @@ namespace GUIEngine }; - /** - * \ingroup guiengine - * \brief Loads a GUI screen from its XML file. - * Builds a hierarchy of Widget objects whose contents are a direct transcription of the XML file, - * with little analysis or layout performed on them. - */ - void parseScreenFileDiv(irr::io::IrrXMLReader* xml, ptr_vector& append_to); - /** * \brief Represents a single GUI screen. * Mainly responsible of its children widgets; Screen lays them @@ -109,6 +101,14 @@ namespace GUIEngine bool m_throttle_FPS; + /** + * \ingroup guiengine + * \brief Loads a GUI screen from its XML file. + * Builds a hierarchy of Widget objects whose contents are a direct transcription of the XML file, + * with little analysis or layout performed on them. + */ + static void parseScreenFileDiv(irr::io::IrrXMLReader* xml, ptr_vector& append_to); + public: @@ -226,6 +226,8 @@ namespace GUIEngine virtual void eventCallback(Widget* widget, const std::string& name, const int playerID) = 0; virtual void onUpdate(float dt, irr::video::IVideoDriver*) { }; + + }; } diff --git a/src/guiengine/screen_loader.cpp b/src/guiengine/screen_loader.cpp index 713b6304f..0dd2d3b66 100644 --- a/src/guiengine/screen_loader.cpp +++ b/src/guiengine/screen_loader.cpp @@ -34,7 +34,7 @@ using namespace io; using namespace gui; using namespace GUIEngine; -void GUIEngine::parseScreenFileDiv(irr::io::IrrXMLReader* xml, ptr_vector& append_to) +void Screen::parseScreenFileDiv(irr::io::IrrXMLReader* xml, ptr_vector& append_to) { // parse XML file while(xml && xml->read()) diff --git a/src/guiengine/widget.hpp b/src/guiengine/widget.hpp index 72baf0972..27bbc732b 100644 --- a/src/guiengine/widget.hpp +++ b/src/guiengine/widget.hpp @@ -111,9 +111,7 @@ namespace GUIEngine */ class Widget : public SkinWidgetContainer { - protected: - friend void GUIEngine::parseScreenFileDiv(irr::io::IrrXMLReader* xml, ptr_vector& append_to); - + protected: unsigned int m_magic_number; friend class EventHandler;