summaryrefslogtreecommitdiffabout
path: root/korganizer/mainwindow.h
Unidiff
Diffstat (limited to 'korganizer/mainwindow.h') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/mainwindow.h115
1 files changed, 115 insertions, 0 deletions
diff --git a/korganizer/mainwindow.h b/korganizer/mainwindow.h
new file mode 100644
index 0000000..ee4aaa6
--- a/dev/null
+++ b/korganizer/mainwindow.h
@@ -0,0 +1,115 @@
1#ifndef KORGE_MAINWINDOW_H
2#define KORGE_MAINWINDOW_H
3
4#include <qmainwindow.h>
5#include <qtimer.h>
6#include <qdict.h>
7
8#include <libkcal/incidence.h>
9#include "simplealarmclient.h"
10
11class QAction;
12class CalendarView;
13class KSyncProfile;
14#ifdef DESKTOP_VERSION
15
16#define QPEToolBar QToolBar
17#define QPEMenuBar QMenuBar
18#endif
19class QPEToolBar;
20
21namespace KCal {
22class CalendarLocal;
23}
24
25using namespace KCal;
26
27class MainWindow : public QMainWindow
28{
29 Q_OBJECT
30 public:
31 MainWindow( QWidget *parent = 0, const char *name = 0, QString command = "");
32 ~MainWindow();
33 public slots:
34 void configureAgenda( int );
35 void recieve( const QCString& msg, const QByteArray& data );
36 static QString defaultFileName();
37 static QString resourcePath();
38 protected slots:
39 void setCaptionToDates();
40 int ringSync();
41 void multiSync( bool askforPrefs = false );
42 void about();
43 void faq();
44 void usertrans();
45 void features();
46 void synchowto();
47 void whatsNew();
48 void keyBindings();
49 void aboutAutoSaving();;
50 void aboutKnownBugs();
51
52 void processIncidenceSelection( Incidence * );
53
54 void importQtopia();
55 void importBday();
56 void importIcal();
57 void importFile( QString, bool );
58 void quickImportIcal();
59
60 void slotModifiedChanged( bool );
61
62 void save();
63 void configureToolBar( int );
64 void printSel();
65 void printCal();
66 void saveCalendar();
67 void loadCalendar();
68 void exportVCalendar();
69
70 void slotSyncMenu( int );
71 void syncSSH();
72 void confSync();
73 void syncSharp();
74 void syncLocalFile();
75 bool syncWithFile( QString, bool );
76 void quickSyncLocalFile();
77
78
79 protected:
80 void displayText( QString, QString);
81 void displayFile( QString, QString);
82
83 void enableIncidenceActions( bool );
84
85 private:
86 void saveOnClose();
87 int mCurrentSyncProfile;
88 void syncRemote( KSyncProfile* , bool ask = true);
89 void fillSyncMenu();
90 bool mFlagKeyPressed;
91 bool mBlockAtStartup;
92 QPEToolBar *iconToolBar;
93 void initActions();
94 void setDefaultPreferences();
95 void keyPressEvent ( QKeyEvent * ) ;
96 void keyReleaseEvent ( QKeyEvent * ) ;
97 QPopupMenu *configureToolBarMenu;
98 QPopupMenu *configureAgendaMenu, *syncMenu;
99 CalendarLocal *mCalendar;
100 CalendarView *mView;
101 QString getPassword();
102 QAction *mNewSubTodoAction;
103
104 QAction *mShowAction;
105 QAction *mEditAction;
106 QAction *mDeleteAction;
107 void closeEvent( QCloseEvent* ce );
108 SimpleAlarmClient mAlarmClient;
109 QTimer mSaveTimer;
110 bool mBlockSaveFlag;
111 bool mCalendarModifiedFlag;
112 QPixmap loadPixmap( QString );
113};
114
115#endif