2012-08-01 16:29:22 -05:00
|
|
|
#pragma once
|
|
|
|
|
2013-03-22 09:14:17 -05:00
|
|
|
#include "gui/interface/Window.h"
|
2012-08-01 16:29:22 -05:00
|
|
|
|
|
|
|
class Activity
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
virtual void Exit() {}
|
|
|
|
virtual void Show() {}
|
|
|
|
virtual void Hide() {}
|
|
|
|
virtual ~Activity() {}
|
|
|
|
};
|
|
|
|
|
|
|
|
class WindowActivity: public ui::Window, public Activity
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
WindowActivity(ui::Point position, ui::Point size) :
|
|
|
|
ui::Window(position, size)
|
|
|
|
{
|
|
|
|
Show();
|
|
|
|
}
|
|
|
|
virtual void Exit()
|
|
|
|
{
|
|
|
|
Hide();
|
|
|
|
SelfDestruct();
|
|
|
|
}
|
|
|
|
virtual void Show()
|
|
|
|
{
|
2017-07-13 22:24:35 -05:00
|
|
|
MakeActiveWindow();
|
2012-08-01 16:29:22 -05:00
|
|
|
}
|
|
|
|
virtual void Hide()
|
|
|
|
{
|
2017-07-13 22:24:35 -05:00
|
|
|
CloseActiveWindow();
|
2012-08-01 16:29:22 -05:00
|
|
|
}
|
|
|
|
virtual ~WindowActivity() {}
|
2013-05-11 06:08:32 -05:00
|
|
|
};
|