1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-09 21:42:13 +00:00
OpenMW/apps/openmw/mwgui/window_base.hpp

52 lines
1.2 KiB
C++
Raw Normal View History

2010-11-06 10:25:16 +00:00
#ifndef MWGUI_WINDOW_BASE_H
#define MWGUI_WINDOW_BASE_H
#include <openengine/gui/layout.hpp>
namespace MWBase
{
class WindowManager;
}
2010-11-06 10:25:16 +00:00
namespace MWGui
{
class WindowManager;
2010-11-06 10:25:16 +00:00
class WindowBase: public OEngine::GUI::Layout
{
public:
WindowBase(const std::string& parLayout, MWBase::WindowManager& parWindowManager);
2010-11-06 10:25:16 +00:00
// Events
typedef MyGUI::delegates::CMultiDelegate1<WindowBase*> EventHandle_WindowBase;
virtual void open() {}
virtual void close () {}
virtual void setVisible(bool visible);
2010-11-06 10:25:16 +00:00
void center();
/** Event : Dialog finished, OK button clicked.\n
signature : void method()\n
*/
EventHandle_WindowBase eventDone;
2010-11-06 10:25:16 +00:00
protected:
/// \todo remove
MWBase::WindowManager& mWindowManager;
2010-11-06 10:25:16 +00:00
};
/*
* "Modal" windows cause the rest of the interface to be unaccessible while they are visible
*/
class WindowModal : public WindowBase
{
public:
WindowModal(const std::string& parLayout, MWBase::WindowManager& parWindowManager);
virtual void open();
virtual void close();
};
2010-11-06 10:25:16 +00:00
}
#endif