diff options
| author | manuel <manuel@mausz.at> | 2011-04-06 14:32:09 +0200 |
|---|---|---|
| committer | manuel <manuel@mausz.at> | 2011-04-06 14:32:09 +0200 |
| commit | 6dc8b50817fe5da8550c245db755f7014402c62a (patch) | |
| tree | c2c657b7f7103c436003788d4f0b45758cb2dfd8 /pacman-c++/block.h | |
| parent | 3cdc77bc7d1da312a0c7ae9c734f6a33f1c49ecf (diff) | |
| download | foop-6dc8b50817fe5da8550c245db755f7014402c62a.tar.gz foop-6dc8b50817fe5da8550c245db755f7014402c62a.tar.bz2 foop-6dc8b50817fe5da8550c245db755f7014402c62a.zip | |
some minor cleanup
Diffstat (limited to 'pacman-c++/block.h')
| -rw-r--r-- | pacman-c++/block.h | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/pacman-c++/block.h b/pacman-c++/block.h index 034a626..40bde51 100644 --- a/pacman-c++/block.h +++ b/pacman-c++/block.h | |||
| @@ -8,12 +8,20 @@ | |||
| 8 | class Block | 8 | class Block |
| 9 | : public PixmapItem | 9 | : public PixmapItem |
| 10 | { | 10 | { |
| 11 | enum Neighbour { | ||
| 12 | None = 0, | ||
| 13 | Left = (1 << 0), | ||
| 14 | Right = (1 << 1), | ||
| 15 | Up = (1 << 2), | ||
| 16 | Down = (1 << 3) | ||
| 17 | }; | ||
| 18 | |||
| 11 | public: | 19 | public: |
| 12 | Block(Color color, QGraphicsItem *parent=0); | 20 | Block(Color::Color color, Neighbour neighbour = None, QGraphicsItem *parent = 0); |
| 13 | 21 | ||
| 14 | private: | 22 | private: |
| 15 | // map for saving QPixmaps for reuse | 23 | // map for saving QPixmaps for reuse |
| 16 | static QMap<Color, QPixmap> m_pixmaps; | 24 | static QMap<Color::Color, QPixmap> m_pixmaps; |
| 17 | }; | 25 | }; |
| 18 | 26 | ||
| 19 | #endif // BLOCK_H | 27 | #endif // BLOCK_H |
