aboutsummaryrefslogtreecommitdiff
path: root/engines/wage/macwindowmanager.h
diff options
context:
space:
mode:
Diffstat (limited to 'engines/wage/macwindowmanager.h')
-rw-r--r--engines/wage/macwindowmanager.h72
1 files changed, 68 insertions, 4 deletions
diff --git a/engines/wage/macwindowmanager.h b/engines/wage/macwindowmanager.h
index 0c35356863..13f85cddd4 100644
--- a/engines/wage/macwindowmanager.h
+++ b/engines/wage/macwindowmanager.h
@@ -48,28 +48,92 @@
#ifndef WAGE_MACWINDOWMANAGER_H
#define WAGE_MACWINDOWMANAGER_H
+#include "common/array.h"
+#include "common/list.h"
+#include "common/events.h"
+#include "common/archive.h"
+
+#include "graphics/fontman.h"
+
+namespace Graphics {
+class ManagedSurface;
+}
+
namespace Wage {
+enum {
+ kDesktopArc = 7
+};
+
+enum {
+ kColorBlack = 0,
+ kColorGray = 1,
+ kColorWhite = 2,
+ kColorGreen = 3,
+ kColorGreen2 = 4
+};
+
+enum {
+ kPatternSolid = 1,
+ kPatternStripes = 2,
+ kPatternCheckers = 3,
+ kPatternCheckers2 = 4
+};
+
+class BaseMacWindow;
class MacWindow;
+class Menu;
+
+typedef Common::Array<byte *> Patterns;
class MacWindowManager {
public:
MacWindowManager();
~MacWindowManager();
- int add(bool scrollable);
+ void setScreen(Graphics::ManagedSurface *screen) { _screen = screen; }
+ bool hasBuiltInFonts() { return _builtInFonts; }
+ const Graphics::Font *getFont(const char *name, Graphics::FontManager::FontUsage fallback);
+
+ MacWindow *addWindow(bool scrollable, bool resizable, bool editable);
+ Menu *addMenu();
void setActive(int id);
- void draw(Graphics::Surface *g);
+ void setFullRefresh(bool redraw) { _fullRefresh = true; }
+
+ void draw();
+
+ bool processEvent(Common::Event &event);
+
+ BaseMacWindow *getWindow(int id) { return _windows[id]; }
+
+ Patterns &getPatterns() { return _patterns; }
+ void drawFilledRoundRect(Graphics::ManagedSurface *surface, Common::Rect &rect, int arc, int color);
+
+ void pushArrowCursor();
+ void popCursor();
private:
- Common::List<MacWindow *> _windowStack;
- Common::Array<MacWindow *> _windows;
+ void drawDesktop();
+ void loadFonts();
+
+private:
+ Graphics::ManagedSurface *_screen;
+
+ Common::List<BaseMacWindow *> _windowStack;
+ Common::Array<BaseMacWindow *> _windows;
int _lastId;
int _activeWindow;
bool _fullRefresh;
+
+ Patterns _patterns;
+
+ Menu *_menu;
+
+ bool _builtInFonts;
+ bool _cursorIsArrow;
};
} // End of namespace Wage