Updated the web pages
[ghostsoverboard] / seascene.h
index 0e2a513..963f3d1 100644 (file)
 #include<QGraphicsItemGroup>
 #include "screenlitkeeper.h"
 #include "level.h"
+#include "levelset.h"
 #include <QAction>
 #include <QTimer>
+#include <QSystemDeviceInfo>
+#include <QTime>
+
+using namespace QtMobility;
 
 class SeaScene : public QGraphicsScene
 {
@@ -43,6 +48,9 @@ signals:
     void pauseOn();
     void pauseOff();
     void vibrationActivated(bool on);
+    void minimizeRequested();
+    void fullscreenRequested();
+    void deviceJustLocked();
 
 public slots:
 
@@ -80,6 +88,16 @@ public slots:
 
     void softContinue();
 
+    void setItemPointersNull();
+
+    void turnPauseOn();
+
+    void handleDeviceLocked(bool isLocked);
+
+    void pollDeviceLocked();
+
+
+
 
 
 protected:
@@ -92,6 +110,10 @@ protected:
 
     void createMenuItems();
     void prepareForMenu(QGraphicsItem * pItem);
+    void createAboutBoxItems();
+    void createVictoryItems();
+    void createLevelCompletedItems();
+    void createSelectLevelsetFromListItems();
 
     const QString ghostImageFilename_;
     const QString rockImageFilename_;
@@ -108,7 +130,6 @@ protected:
 
     ScreenLitKeeper screenLitKeeper_;
 
-
     int menuItemCount_;
 
     QGraphicsTextItem * pPausetextItem_;
@@ -118,8 +139,22 @@ protected:
     QGraphicsTextItem * pSettingsItem_;
     QGraphicsTextItem * pAboutItem_;
     QGraphicsTextItem * pQuitItem_;
+    QGraphicsTextItem * pMinimizeItem_;
+    QGraphicsTextItem * pChooseLevelsetItem_;
+
+    QGraphicsTextItem * pVictoryCongratulationsItem_;
+    QGraphicsTextItem * pVictoryScoreItem_;
+    QGraphicsTextItem * pAboutBoxItem_;
 
-    QList<Level> levelList_;
+    QGraphicsTextItem * pLevelCompletedItem_;
+
+    QGraphicsTextItem * pSelectLevelsetFromListItem_;
+
+    QList<QGraphicsItem *>  levelsetItems_;
+
+    QList<Levelset> availableLevelsets_;
+
+    Levelset levelset_;
 
     int currentLevel_;
 
@@ -128,10 +163,18 @@ protected:
 
     QAction* pPauseAction_;
 
-    bool pauseForced_;
-
     QTimer autopauseTimer;
 
+    QSystemDeviceInfo deviceInfo_;
+
+    bool alreadyLocked_;
+
+    QTimer deviceLockPollTimer_;
+
+    QTime scoreCounter_;
+    int totalScore_;
+    int levelScore_;
+
 };
 
 #endif // SEASCENE_H