Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStijn Buys <ingar@osirion.org>2010-12-08 20:19:21 +0000
committerStijn Buys <ingar@osirion.org>2010-12-08 20:19:21 +0000
commit82992a9b16d64104dd28d42e97cc118a75fded86 (patch)
treea7c30cedd613196c06df3fc04f6bce015c3927c1 /src/client/infowidget.h
parent1124a81de517375a012b89bf83462c091d472cab (diff)
Added clock.
Diffstat (limited to 'src/client/infowidget.h')
-rw-r--r--src/client/infowidget.h29
1 files changed, 27 insertions, 2 deletions
diff --git a/src/client/infowidget.h b/src/client/infowidget.h
index 48d1c9a..e773ef4 100644
--- a/src/client/infowidget.h
+++ b/src/client/infowidget.h
@@ -52,12 +52,37 @@ private:
class KeyInfoWidget : public ui::Widget
{
public:
- // default constructor
+ /// default constructor
KeyInfoWidget(ui::Widget *parent = 0);
protected:
- // draw keypress events
+ /// draw keypress events
+ virtual void draw();
+};
+
+/// a widget to show keypress events
+class ClockInfoWidget : public ui::Widget
+{
+public:
+ /// clock mode
+ enum Mode {ClockOff=0, Clock24Hours=1, Clock12Hours=2};
+
+ /// default constructor
+ ClockInfoWidget(ui::Widget *parent = 0);
+
+ inline void set_mode(const Mode mode) {
+ clock_mode = mode;
+ }
+
+ inline const Mode mode() const {
+ return clock_mode;
+ }
+
+protected:
+ /// draw the current time
virtual void draw();
+
+ Mode clock_mode;
};
}