author | zecke <zecke> | 2003-02-23 21:27:08 (UTC) |
---|---|---|
committer | zecke <zecke> | 2003-02-23 21:27:08 (UTC) |
commit | 041eda0d7482d60cd67731b81fd36104fcd3120f (patch) (side-by-side diff) | |
tree | c7bc7730b9e76e22f828291d404821f7bd922d6f /core/pim/datebook2/mainwindow.h | |
parent | a195865dfdb03b4c7c972acfc8cfd87743ab3e6f (diff) | |
download | opie-041eda0d7482d60cd67731b81fd36104fcd3120f.zip opie-041eda0d7482d60cd67731b81fd36104fcd3120f.tar.gz opie-041eda0d7482d60cd67731b81fd36104fcd3120f.tar.bz2 |
Implement some of the new framework
Diffstat (limited to 'core/pim/datebook2/mainwindow.h') (more/less context) (show whitespace changes)
-rw-r--r-- | core/pim/datebook2/mainwindow.h | 60 |
1 files changed, 59 insertions, 1 deletions
diff --git a/core/pim/datebook2/mainwindow.h b/core/pim/datebook2/mainwindow.h index 5ea0c89..60ea4c4 100644 --- a/core/pim/datebook2/mainwindow.h +++ b/core/pim/datebook2/mainwindow.h @@ -2,40 +2,98 @@ #define DATE_BOOK_MAIN_WINDOW_H #include <qlist.h> #include <opie/opimmainwindow.h> +#include "descriptionmanager.h" +#include "locationmanager.h" +#include "view.h" + +class QAction; +class QWidgetStack; +class QPopupMenu; +class QPEToolBar; namespace Datebook { + class TemplateManager; + class BookManager; + class Show; class MainWindow : public OPimMainWindow { Q_OBJECT + friend class Show; // to avoid QObject + friend class View; // to avoid QObject public: MainWindow(); ~MainWindow(); private slots: void initUI(); // init the UI void initConfig(); // apply the config void initView(); // init the Views.. void initManagers(); // init the Managers including templates, location and description void raiseCurrentView(); // raise the current View + void slotGoToNow(); // will switch the currentView to the curren date time + void slotFind(); // find!!! + void slotConfigure(); // configure the app + void slotClockChanged(bool); // clock changed + void slotWeekChanged( bool ); // week changed + void slotAppMessage( const QCString&, const QByteArray& ); // qApp message QPE/Application/datebook + void slotReceive( const QCString&, const QByteArray& ); // QPE/System and QPE/Datebook + void slotAction( QAction* ); // View changed + void slotConfigureLocs(); // Configure the Locations + void slotConfigureDesc(); // Configure the Desc + protected slots: void populate(); void doSetDocument( const QString& str ); void flush(); void reload(); int create(); bool remove( int uid ); void beam( int uid ); void show( int uid ); void edit( int uid ); + void edit(); void add( const OPimRecord& ); private: - QList<View> m_view; // the Views.. not autoDelete + QPEToolBar* toolbar(); + QPopupMenu* viewMenu(); + QPopupMenu* settingsMenu(); + QPopupMenu* templateMenu(); + View* currentView(); + BookManager* manager(); + TemplateManager* templateManager(); + LocationManager* locationManager(); + DescriptionManager* descriptionManager(); + Show* eventShow(); + + private: // friend functions for Show + void hideShow(); // to hide the view + // off friend Show + // friend of the view + private: + void viewPopup( int ); + void viewAdd( const QDate& date ); + void viewAdd( const QDateTime&, const QDateTime& ); + bool viewAP()const; + bool viewStartMonday()const; + // off view show + private: + QList<View> m_view; // the Views.. not autoDelete + QWidgetStack* m_stack; + QPEToolBar *m_toolBar; + QPopupMenu* m_popView; + QPopupMenu* m_popSetting; + QPopupMenu* m_popTemplate; + BookManager* m_manager; + TemplateManager* m_tempMan; + DescriptionManager* m_descMan; + LocationManager* m_locMan; + Show* m_show; }; } #endif |