mainwindow.h 726 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. #ifndef MAINWINDOW_H
  2. #define MAINWINDOW_H
  3. #include <QtGui/QMainWindow>
  4. #include <QTimer>
  5. namespace Ui {
  6. class MainWindow;
  7. }
  8. class MainWindow : public QMainWindow
  9. {
  10. Q_OBJECT
  11. public:
  12. enum ScreenOrientation {
  13. ScreenOrientationLockPortrait,
  14. ScreenOrientationLockLandscape,
  15. ScreenOrientationAuto
  16. };
  17. explicit MainWindow(QWidget *parent = 0);
  18. virtual ~MainWindow();
  19. // Note that this will only have an effect on Symbian and Fremantle.
  20. void setOrientation(ScreenOrientation orientation);
  21. void showExpanded();
  22. public slots:
  23. void UpdateTime();
  24. private:
  25. Ui::MainWindow *ui;
  26. QTimer m_timer;
  27. };
  28. #endif // MAINWINDOW_H