-rw-r--r-- | korganizer/mainwindow.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/korganizer/mainwindow.h b/korganizer/mainwindow.h index e2de3ba..7d3d492 100644 --- a/korganizer/mainwindow.h +++ b/korganizer/mainwindow.h | |||
@@ -9,165 +9,170 @@ | |||
9 | #include <qtextstream.h> | 9 | #include <qtextstream.h> |
10 | #include <qregexp.h> | 10 | #include <qregexp.h> |
11 | 11 | ||
12 | #include <libkcal/incidence.h> | 12 | #include <libkcal/incidence.h> |
13 | #include <ksyncmanager.h> | 13 | #include <ksyncmanager.h> |
14 | #include <kpopupmenu.h> | 14 | #include <kpopupmenu.h> |
15 | #ifndef DESKTOP_VERSION | 15 | #ifndef DESKTOP_VERSION |
16 | #include <qcopchannel_qws.h> | 16 | #include <qcopchannel_qws.h> |
17 | #endif | 17 | #endif |
18 | class QAction; | 18 | class QAction; |
19 | class CalendarView; | 19 | class CalendarView; |
20 | class KSyncProfile; | 20 | class KSyncProfile; |
21 | #ifdef DESKTOP_VERSION | 21 | #ifdef DESKTOP_VERSION |
22 | 22 | ||
23 | #define QPEToolBar QToolBar | 23 | #define QPEToolBar QToolBar |
24 | #endif | 24 | #endif |
25 | class QPEToolBar; | 25 | class QPEToolBar; |
26 | 26 | ||
27 | 27 | ||
28 | namespace KCal { | 28 | namespace KCal { |
29 | class CalendarLocal; | 29 | class CalendarLocal; |
30 | } | 30 | } |
31 | 31 | ||
32 | using namespace KCal; | 32 | using namespace KCal; |
33 | 33 | ||
34 | class MainWindow : public QMainWindow | 34 | class MainWindow : public QMainWindow |
35 | { | 35 | { |
36 | Q_OBJECT | 36 | Q_OBJECT |
37 | public: | 37 | public: |
38 | MainWindow( QWidget *parent = 0, const char *name = 0 ); | 38 | MainWindow( QWidget *parent = 0, const char *name = 0 ); |
39 | ~MainWindow(); | 39 | ~MainWindow(); |
40 | bool beamReceiveEnabled(); | 40 | bool beamReceiveEnabled(); |
41 | static QString defaultFileName(); | 41 | static QString defaultFileName(); |
42 | static QString syncFileName(); | 42 | static QString syncFileName(); |
43 | static QString resourcePath(); | 43 | static QString resourcePath(); |
44 | public slots: | 44 | public slots: |
45 | void setUsesBigPixmaps ( bool ); | 45 | void setUsesBigPixmaps ( bool ); |
46 | void setCaption ( const QString & ); | 46 | void setCaption ( const QString & ); |
47 | void updateWeekNum(const KCal::DateList &); | 47 | void updateWeekNum(const KCal::DateList &); |
48 | void updateWeek(QDate); | 48 | void updateWeek(QDate); |
49 | void updateFilterToolbar(); | 49 | void updateFilterToolbar(); |
50 | virtual void showMaximized (); | 50 | virtual void showMaximized (); |
51 | void configureAgenda( int ); | 51 | void configureAgenda( int ); |
52 | void recieve( const QCString& msg, const QByteArray& data ); | 52 | void recieve( const QCString& msg, const QByteArray& data ); |
53 | protected slots: | 53 | protected slots: |
54 | void calHint(); | 54 | void calHint(); |
55 | void startMultiSync(); | 55 | void startMultiSync(); |
56 | void setCaptionToDates(); | 56 | void setCaptionToDates(); |
57 | void weekAction(); | 57 | void weekAction(); |
58 | void about(); | 58 | void about(); |
59 | void licence(); | 59 | void licence(); |
60 | void faq(); | 60 | void faq(); |
61 | void usertrans(); | 61 | void usertrans(); |
62 | void features(); | 62 | void features(); |
63 | void synchowto(); | 63 | void synchowto(); |
64 | void storagehowto(); | 64 | void storagehowto(); |
65 | void timetrackinghowto(); | 65 | void timetrackinghowto(); |
66 | void kdesynchowto(); | 66 | void kdesynchowto(); |
67 | void multisynchowto(); | 67 | void multisynchowto(); |
68 | void whatsNew(); | 68 | void whatsNew(); |
69 | void keyBindings(); | 69 | void keyBindings(); |
70 | void aboutAutoSaving();; | 70 | void aboutAutoSaving();; |
71 | void aboutKnownBugs(); | 71 | void aboutKnownBugs(); |
72 | 72 | ||
73 | void processIncidenceSelection( Incidence * ); | 73 | void processIncidenceSelection( Incidence * ); |
74 | 74 | ||
75 | void importQtopia(); | 75 | void importQtopia(); |
76 | void importBday(); | 76 | void importBday(); |
77 | void importOL(); | 77 | void importOL(); |
78 | void importIcal(); | 78 | void importIcal(); |
79 | void importFile( QString, bool ); | 79 | void importFile( QString, bool ); |
80 | void quickImportIcal(); | 80 | void quickImportIcal(); |
81 | 81 | ||
82 | void slotModifiedChanged( bool ); | 82 | void slotModifiedChanged( bool ); |
83 | 83 | ||
84 | void save(); | 84 | void save(); |
85 | void backupAllFiles(); | 85 | void backupAllFiles(); |
86 | void saveStopTimer(); | 86 | void saveStopTimer(); |
87 | void configureToolBar( int ); | 87 | void configureToolBar( int ); |
88 | void printSel(); | 88 | void printSel(); |
89 | void printCal(); | 89 | void printCal(); |
90 | void printListView(); | 90 | void printListView(); |
91 | void saveCalendar(); | 91 | void saveCalendar(); |
92 | void loadCalendar(); | 92 | void loadCalendar(); |
93 | void exportVCalendar(); | 93 | void exportVCalendar(); |
94 | void fillFilterMenu(); | 94 | void fillFilterMenu(); |
95 | void fillFilterMenuTB(); | 95 | void fillFilterMenuTB(); |
96 | void selectFilter( int ); | 96 | void selectFilter( int ); |
97 | void fillFilterMenuPopup(); | 97 | void fillFilterMenuPopup(); |
98 | void selectFilterPopup( int ); | 98 | void selectFilterPopup( int ); |
99 | void exportToPhone( int ); | 99 | void exportToPhone( int ); |
100 | void toggleBeamReceive(); | 100 | void toggleBeamReceive(); |
101 | void disableBR(bool); | 101 | void disableBR(bool); |
102 | signals: | 102 | signals: |
103 | void selectWeek ( int ); | 103 | void selectWeek ( int ); |
104 | private slots: | 104 | private slots: |
105 | void slotResetFocus(); | ||
106 | void slotResetFocusLoop(); | ||
105 | void showConfigureAgenda(); | 107 | void showConfigureAgenda(); |
106 | void getFile( bool ); | 108 | void getFile( bool ); |
107 | void syncFileRequest(); | 109 | void syncFileRequest(); |
108 | 110 | ||
109 | protected: | 111 | protected: |
112 | int mFocusLoop; | ||
110 | void hideEvent ( QHideEvent * ); | 113 | void hideEvent ( QHideEvent * ); |
111 | QString sentSyncFile(); | 114 | QString sentSyncFile(); |
112 | void displayText( QString, QString); | 115 | void displayText( QString, QString); |
113 | void enableIncidenceActions( bool ); | 116 | void enableIncidenceActions( bool ); |
114 | 117 | ||
115 | private: | 118 | private: |
119 | //void setMenuBar( QMenuBar * ); | ||
116 | bool mBRdisabled; | 120 | bool mBRdisabled; |
117 | #ifndef DESKTOP_VERSION | 121 | #ifndef DESKTOP_VERSION |
118 | QCopChannel* infrared; | 122 | QCopChannel* infrared; |
119 | #endif | 123 | #endif |
120 | QAction* brAction; | 124 | QAction* brAction; |
121 | KSyncManager* mSyncManager; | 125 | KSyncManager* mSyncManager; |
122 | bool mClosed; | 126 | bool mClosed; |
123 | void saveOnClose(); | 127 | void saveOnClose(); |
124 | bool mFlagKeyPressed; | 128 | bool mFlagKeyPressed; |
125 | bool mBlockAtStartup; | 129 | bool mBlockAtStartup; |
130 | KMenuBar *menuBar1; | ||
126 | QPEToolBar *iconToolBar; | 131 | QPEToolBar *iconToolBar; |
127 | QPEToolBar *viewToolBar; | 132 | QPEToolBar *viewToolBar; |
128 | QPEToolBar *navigatorToolBar; | 133 | QPEToolBar *navigatorToolBar; |
129 | QPEToolBar *filterToolBar; | 134 | QPEToolBar *filterToolBar; |
130 | KMenuBar *filterMenubar; | 135 | KMenuBar *filterMenubar; |
131 | QPopupMenu * filterPopupMenu; | 136 | QPopupMenu * filterPopupMenu; |
132 | QPopupMenu * mCurrentItemMenu; | 137 | QPopupMenu * mCurrentItemMenu; |
133 | void initActions(); | 138 | void initActions(); |
134 | void setDefaultPreferences(); | 139 | void setDefaultPreferences(); |
135 | void resizeEvent( QResizeEvent* e); | 140 | void resizeEvent( QResizeEvent* e); |
136 | void keyPressEvent ( QKeyEvent * ) ; | 141 | void keyPressEvent ( QKeyEvent * ) ; |
137 | void keyReleaseEvent ( QKeyEvent * ) ; | 142 | void keyReleaseEvent ( QKeyEvent * ) ; |
138 | QPopupMenu *configureToolBarMenu; | 143 | QPopupMenu *configureToolBarMenu; |
139 | QPopupMenu *selectFilterMenu; | 144 | QPopupMenu *selectFilterMenu; |
140 | QPopupMenu *selectFilterMenuTB; | 145 | QPopupMenu *selectFilterMenuTB; |
141 | QPopupMenu *configureAgendaMenu, *syncMenu; | 146 | QPopupMenu *configureAgendaMenu, *syncMenu; |
142 | CalendarLocal *mCalendar; | 147 | CalendarLocal *mCalendar; |
143 | CalendarView *mView; | 148 | CalendarView *mView; |
144 | QAction *mNewSubTodoAction; | 149 | QAction *mNewSubTodoAction; |
145 | QAction *mWeekAction; | 150 | QAction *mWeekAction; |
146 | QFont mWeekFont; | 151 | QFont mWeekFont; |
147 | QPixmap mWeekPixmap; | 152 | QPixmap mWeekPixmap; |
148 | QColor mWeekBgColor; | 153 | QColor mWeekBgColor; |
149 | 154 | ||
150 | QAction *mShowAction; | 155 | QAction *mShowAction; |
151 | QAction *mEditAction; | 156 | QAction *mEditAction; |
152 | QAction *mDeleteAction; | 157 | QAction *mDeleteAction; |
153 | QAction *mCloneAction; | 158 | QAction *mCloneAction; |
154 | QAction *mMoveAction; | 159 | QAction *mMoveAction; |
155 | QAction *mBeamAction; | 160 | QAction *mBeamAction; |
156 | QAction *mCancelAction; | 161 | QAction *mCancelAction; |
157 | QAction *mPrintSelAction; | 162 | QAction *mPrintSelAction; |
158 | 163 | ||
159 | QAction *mToggleNav; | 164 | QAction *mToggleNav; |
160 | QAction *mToggleFilter; | 165 | QAction *mToggleFilter; |
161 | QAction *mToggleAllday; | 166 | QAction *mToggleAllday; |
162 | QAction *actionFilterMenuTB; | 167 | QAction *actionFilterMenuTB; |
163 | 168 | ||
164 | void closeEvent( QCloseEvent* ce ); | 169 | void closeEvent( QCloseEvent* ce ); |
165 | QTimer mSaveTimer; | 170 | QTimer mSaveTimer; |
166 | //bool mBlockSaveFlag; | 171 | //bool mBlockSaveFlag; |
167 | bool mCalendarModifiedFlag; | 172 | bool mCalendarModifiedFlag; |
168 | QPixmap loadPixmap( QString ); | 173 | QPixmap loadPixmap( QString ); |
169 | QPixmap listviewPix, listviewPix0, listviewPix20, listviewPix40, listviewPix60, listviewPix80, journalPix; | 174 | QPixmap listviewPix, listviewPix0, listviewPix20, listviewPix40, listviewPix60, listviewPix80, journalPix; |
170 | }; | 175 | }; |
171 | 176 | ||
172 | 177 | ||
173 | #endif | 178 | #endif |