Added altitude display to detail screen. Added option to disable auto rotation.
[jspeed] / src / orientation.h
index 193f687..5848f22 100644 (file)
@@ -29,8 +29,10 @@ class Orientation : public QtMobility::QOrientationSensor
 
 public:
     enum OrientationName {LANDSCAPE = 0x01, PORTRAIT = 0x02};
+    enum OrientationType {TYPE_AUTO, TYPE_LANDSCAPE, TYPE_PORTRAIT};
     Orientation(QMainWindow* window);
     void setSupportedOrientations(int orientations);
+    void setOrientationType(OrientationType type);
 
 public slots:
     void update();
@@ -40,11 +42,13 @@ signals:
 
 private slots:
     void onReadingChanged();
+    void handleManualOrientation();
 
 private:
     QtMobility::QOrientationReading::Orientation current_;
     int orientations_;
     QMainWindow* window_;
+    OrientationType type_;
 };
 
 #endif