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