summaryrefslogtreecommitdiffstats
path: root/src/ui/key.h
diff options
context:
space:
mode:
authorZaba999 <zaba.marcin@gmail.com>2012-09-10 23:29:38 +0200
committerZaba999 <zaba.marcin@gmail.com>2012-09-10 23:29:38 +0200
commit479a67a731be5a5e8035ea7acce0344c7c605814 (patch)
treefc0448b4095ce03aeca2a1be98418aae78751d84 /src/ui/key.h
parentcf2295d08d0b2d0ba63e316f5e5e3615c5c978ac (diff)
downloadcolobot-479a67a731be5a5e8035ea7acce0344c7c605814.tar.gz
colobot-479a67a731be5a5e8035ea7acce0344c7c605814.tar.bz2
colobot-479a67a731be5a5e8035ea7acce0344c7c605814.zip
Merge with changes from Zaba999 fork.
Diffstat (limited to 'src/ui/key.h')
-rw-r--r--src/ui/key.h41
1 files changed, 25 insertions, 16 deletions
diff --git a/src/ui/key.h b/src/ui/key.h
index 314f39b..5ca71b0 100644
--- a/src/ui/key.h
+++ b/src/ui/key.h
@@ -1,5 +1,6 @@
// * This file is part of the COLOBOT source code
// * Copyright (C) 2001-2008, Daniel ROUX & EPSITEC SA, www.epsitec.ch
+// * Copyright (C) 2012 Polish Portal of Colobot (PPC)
// *
// * This program is free software: you can redistribute it and/or modify
// * it under the terms of the GNU General Public License as published by
@@ -18,35 +19,43 @@
#pragma once
+#include <cctype>
+#include <string>
-#include "ui/control.h"
+#include <ui/control.h>
+#include <common/iman.h>
+#include <common/event.h>
+#include <common/restext.h>
+#include <common/key.h>
-class CD3DEngine;
-
+#include <app/app.h>
+namespace Ui {
class CKey : public CControl
{
-public:
- CKey(CInstanceManager* iMan);
- virtual ~CKey();
+ public:
+ CKey();
+ virtual ~CKey();
- bool Create(Math::Point pos, Math::Point dim, int icon, EventMsg eventMsg);
+ bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
+ bool EventProcess(const Event &event);
- bool EventProcess(const Event &event);
+ void Draw();
- void Draw();
+ void SetKey(int option, int key);
+ int GetKey(int option);
- void SetKey(int option, int key);
- int RetKey(int option);
+ protected:
+ bool TestKey(int key);
-protected:
- bool TestKey(int key);
+ int m_key[2];
+ bool m_bCatch;
-protected:
- int m_key[2];
- bool m_bCatch;
+ CApplication *m_app;
};
+}
+