korganizer.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030 #ifndef KORGANIZER_H
00031 #define KORGANIZER_H
00032
00033 #include <qframe.h>
00034 #include <qlayout.h>
00035 #include <qwidget.h>
00036 #include <qptrlist.h>
00037 #include <qtabdialog.h>
00038 #include <qsplitter.h>
00039
00040 #include <ktoolbar.h>
00041 #include <kapplication.h>
00042 #include <klocale.h>
00043 #include <kstatusbar.h>
00044 #include <kmenubar.h>
00045 #include <kurl.h>
00046
00047 #include <libkcal/calendar.h>
00048
00049 #include <korganizer/mainwindow.h>
00050 #include <korganizer/part.h>
00051 #include <kparts/mainwindow.h>
00052
00053 #include "calendarview.h"
00054 #include "korganizeriface.h"
00055
00056 class KTempFile;
00057 class KRecentFilesAction;
00058 class KOWindowList;
00059 class KToggleAction;
00060 class KProcess;
00061 class KONewStuff;
00062 class ActionManager;
00063 class CalendarView;
00064
00065 namespace KCal { class CalendarResources; }
00066
00067 using namespace KCal;
00068
00069
00070 typedef KOrg::MainWindow KOrgMainWindow;
00071 typedef KParts::MainWindow KPartsMainWindow;
00072
00081 class KOrganizer : public KPartsMainWindow, virtual public KOrganizerIface,
00082 public KOrgMainWindow
00083 {
00084 Q_OBJECT
00085 public:
00093 KOrganizer( const char *name = 0 );
00094 virtual ~KOrganizer();
00095
00096 void init( bool hasDocument );
00097
00098 KOrg::CalendarViewBase *view() const;
00099 ActionManager *actionManager() { return mActionManager; }
00100
00105 bool openURL( const KURL &url, bool merge = false );
00107 bool saveURL();
00109 bool saveAsURL( const KURL & kurl );
00111 KURL getCurrentURL() const;
00112
00114 bool openURL( QString url );
00116 bool mergeURL( QString url );
00118 bool saveAsURL( QString url );
00120 void closeURL();
00122 QString getCurrentURLasString() const;
00124 virtual bool deleteEvent( QString uid );
00125
00126 bool eventRequest( QString request, QCString receiver, QString ical );
00127 bool eventReply( QString ical );
00128
00129 virtual KXMLGUIFactory *mainGuiFactory() { return factory(); }
00130 virtual KXMLGUIClient *mainGuiClient() { return this; }
00131 virtual QWidget *topLevelWidget() { return this; }
00132
00133 public slots:
00135 void showStatusMessage( const QString & );
00136
00137 protected slots:
00138
00142 void readSettings();
00143
00145 void writeSettings();
00146
00148 void configureToolbars();
00149
00150 void toggleStatusBar();
00151
00152 void statusBarPressed( int );
00153
00155 void setTitle();
00156
00157 void setNumIncoming( int );
00158 void setNumOutgoing( int );
00159
00160 void newMainWindow( const KURL & );
00161
00162 void configureKeyBindings();
00163
00164 protected:
00165 void initActions();
00166
00167
00169 bool queryClose();
00170 bool queryExit();
00171
00172
00173 void saveProperties( KConfig * );
00174 void readProperties( KConfig * );
00175
00176 private:
00177 CalendarView *mCalendarView;
00178 KOrg::Part::List mParts;
00179
00180 KToggleAction *mStatusBarAction;
00181
00182
00183 enum { ID_HISTORY, ID_GENERAL, ID_ACTIVE, ID_MESSAGES_IN, ID_MESSAGES_OUT };
00184 ActionManager *mActionManager;
00185 };
00186
00187 #endif
This file is part of the documentation for korganizer Library Version 3.2.2.