]> git.tdb.fi Git - r2c2.git/blob - source/engineer/clockwidget.h
Better graphics for the clock
[r2c2.git] / source / engineer / clockwidget.h
1 #ifndef CLOCKWIDGET_H_
2 #define CLOCKWIDGET_H_
3
4 #include <msp/gltk/widget.h>
5 #include "libr2c2/clock.h"
6
7 class ClockWidget: public Msp::GLtk::Widget
8 {
9 private:
10         R2C2::Clock &clock;
11         Msp::GL::Mesh hour_hand;
12         Msp::GL::Mesh minute_hand;
13
14 public:
15         ClockWidget(R2C2::Clock &);
16
17         virtual const char *get_class() const { return "clock"; }
18
19 private:
20         virtual void rebuild_special(const Msp::GLtk::Part &);
21         virtual void render_special(const Msp::GLtk::Part &, Msp::GL::Renderer &) const;
22 };
23
24 #endif