Make orientation switch explicit on Symbian, too.
[dorian] / fullscreenwindow.h
1 #ifndef FULLSCREENWINDOW_H
2 #define FULLSCREENWINDOW_H
3
4 #include <QRect>
5 #include <QObject>
6
7 #include "adopterwindow.h"
8
9 class QWidget;
10 class QMouseEvent;
11 class QResizeEvent;
12 class TranslucentButton;
13 class Progress;
14
15 /** A full screen window with a restore button. */
16 class FullScreenWindow: public AdopterWindow
17 {
18     Q_OBJECT
19
20 public:
21     explicit FullScreenWindow(QWidget *parent);
22
23     /**
24      * Adopt children.
25      * Same as @AdopterWindow::takeChildren(), but saves prog, previous
26      * and next, before calling base class method.
27      */
28     void takeChildren(BookView *bookView, Progress *prog,
29                       TranslucentButton *previous, TranslucentButton *next);
30
31 signals:
32     /** Emitted when the restore button is pressed. */
33     void restore();
34
35 protected:
36     /** Handle size (and orientation) change. */
37     void resizeEvent(QResizeEvent *e);
38
39     /** Handle show event. */
40     void showEvent(QShowEvent *e);
41
42 protected slots:
43     /** Re-align adopted child windows. */
44     void placeChildren();
45
46 private:
47     TranslucentButton *restoreButton;
48 };
49
50 #endif // FULLSCREENWINDOW_H