forked from SanskritFritz/bubble-chains
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathgamewidget.h
More file actions
37 lines (24 loc) · 713 Bytes
/
Copy pathgamewidget.h
File metadata and controls
37 lines (24 loc) · 713 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#ifndef GAMEWIDGET_H
#define GAMEWIDGET_H
#include <QtGui>
class GameScene;
class GameWidget : public QGraphicsView
{
Q_OBJECT
public:
GameWidget(const QString &respath, QWidget *parent = 0);
~GameWidget();
static const QString& getResourcePath() { return resourcePath; }
public slots:
void setVideoMode();
void playRandomMusic();
protected:
void closeEvent(QCloseEvent *event);
private:
void drawBackground ( QPainter * painter, const QRectF & rect );
void keyPressEvent ( QKeyEvent * keyEvent );
void focusOutEvent ( QFocusEvent * event );
GameScene *scene;
static QString resourcePath;
};
#endif // GAMEWIDGET_H