]> git.tdb.fi Git - r2c2.git/blob - source/engineer/clockwidget.h
10c62bc9237a7df89e8977c8dfdefaba2245b8d5
[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 autosize_special(const Msp::GLtk::Part &, Msp::GLtk::Geometry &) const;
21         virtual void rebuild_special(const Msp::GLtk::Part &);
22         virtual void render_special(const Msp::GLtk::Part &, Msp::GL::Renderer &) const;
23 };
24
25 #endif