X-Git-Url: http://vcs.maemo.org/git/?a=blobdiff_plain;f=mainwindow.h;h=c33f33b97336017cedb8ed90a5ebb03d073c3be2;hb=HEAD;hp=f2a5f6fe21bfc63a36eb1533be70d924ffd5fa7c;hpb=9ee78b359a52b91f772c6fe1df35a84a7aca6394;p=dorian diff --git a/mainwindow.h b/mainwindow.h index f2a5f6f..c33f33b 100755 --- a/mainwindow.h +++ b/mainwindow.h @@ -1,7 +1,10 @@ #ifndef MAINWINDOW_H #define MAINWINDOW_H -#include +#include +#include + +#include "adopterwindow.h" class QString; class QModelIndex; @@ -9,56 +12,69 @@ class DevTools; class BookView; class Book; class FullScreenWindow; +class Progress; +class ProgressDialog; +class TranslucentButton; -class MainWindow: public QMainWindow +class MainWindow: public AdopterWindow { Q_OBJECT public: MainWindow(QWidget *parent = 0); - virtual ~MainWindow() {} + ~MainWindow(); + void initialize(); public slots: void showLibrary(); - void showInfo(); + void rotate(); void showSettings(); void showDevTools(); void showBookmarks(); void onCurrentBookChanged(); - void showNormal(); - void showFullScreen(); + void showRegular(); + void showBig(); void onSettingsChanged(const QString &key); - void onChapterLoadStart(); - void onChapterLoadEnd(int index); - void onAddBookmark(); + void onPartLoadStart(); + void onPartLoadEnd(int index); + void onAddBookmark(const QString ¬e); void onGoToBookmark(int index); void showChapters(); void onGoToChapter(int index); + void about(); + void goToNextPage(); + void goToPreviousPage(); + void onBeginUpgrade(int total); + void onUpgrading(const QString &book); + void onEndUpgrade(); + void onBeginLoad(int total); + void onLoading(const QString &book); + void onEndLoad(); protected: - virtual void closeEvent(QCloseEvent *event); + void timerEvent(QTimerEvent *event); private: void setCurrentBook(const QModelIndex ¤t); - QAction *addToolBarAction(const QObject *receiver, const char *member, - const QString &name); BookView *view; QAction *settingsAction; QAction *libraryAction; - QAction *infoAction; + QAction *rotateAction; QAction *devToolsAction; QAction *bookmarksAction; QAction *fullScreenAction; QAction *forwardAction; QAction *backwardAction; - QAction *previousAction; - QAction *nextAction; QAction *chaptersAction; - QToolBar *toolBar; QDialog *settings; DevTools *devTools; QModelIndex mCurrent; FullScreenWindow *fullScreenWindow; + int preventBlankingTimer; + Progress *prog; + TranslucentButton *prev; + TranslucentButton *next; + ProgressDialog *libraryProgress; }; #endif // MAINWINDOW_H