korganizer Library API Documentation

koincidenceeditor.h

00001 /*
00002     This file is part of KOrganizer.
00003 
00004     Copyright (c) 2001,2003 Cornelius Schumacher <schumacher@kde.org>
00005 
00006     This program is free software; you can redistribute it and/or modify
00007     it under the terms of the GNU General Public License as published by
00008     the Free Software Foundation; either version 2 of the License, or
00009     (at your option) any later version.
00010 
00011     This program is distributed in the hope that it will be useful,
00012     but WITHOUT ANY WARRANTY; without even the implied warranty of
00013     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
00014     GNU General Public License for more details.
00015 
00016     You should have received a copy of the GNU General Public License
00017     along with this program; if not, write to the Free Software
00018     Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
00019 
00020     As a special exception, permission is given to link this program
00021     with any edition of Qt, and distribute the resulting executable,
00022     without including the source code for Qt in the source distribution.
00023 */
00024 #ifndef KOINCIDENCEEDITOR_H
00025 #define KOINCIDENCEEDITOR_H
00026 
00027 #include <kdialogbase.h>
00028 
00029 class QDateTime;
00030 
00031 namespace KPIM { class CategorySelectDialog; }
00032 
00033 class KOEditorDetails;
00034 class KOEditorAttachments;
00035 
00036 namespace KCal {
00037 class Calendar;
00038 class Incidence;
00039 }
00040 using namespace KCal;
00041 
00045 class KOIncidenceEditor : public KDialogBase
00046 {
00047     Q_OBJECT
00048   public:
00052     KOIncidenceEditor( const QString &caption, Calendar *calendar,
00053                        QWidget *parent );
00054     virtual ~KOIncidenceEditor();
00055 
00057     virtual void init() = 0;
00059     virtual void modified (int /*change*/=0) {}
00060 
00061     virtual void reload() = 0;
00062 
00063   public slots:
00064     void updateCategoryConfig();
00066     virtual void editIncidence(Incidence *) = 0;
00067 
00068 
00069   signals:
00070     void deleteAttendee( Incidence * );
00071 
00072     void editCategories();
00073     void dialogClose( Incidence * );
00074     void editCanceled( Incidence * );
00075 
00076     void incidenceAdded( Incidence * );
00077     void incidenceChanged( Incidence *oldTodo, Incidence *newTodo );
00078     void incidenceToBeDeleted( Incidence * );
00079     void incidenceDeleted( Incidence * );
00080 
00081   protected slots:
00082     void slotApply();
00083     void slotOk();
00084     void slotCancel();
00085 
00086     virtual void slotLoadTemplate();
00087     virtual void slotSaveTemplate();
00088     
00089     virtual void saveTemplate( const QString & ) = 0;
00090 
00091   protected:
00092     virtual QString type() { return QString::null; }
00093     
00094     void setupAttendeesTab();
00095     void setupAttachmentsTab();
00096 
00097     QString loadTemplate( Calendar *cal, const QString &type,
00098                           const QStringList &templates );
00099     void saveAsTemplate( Incidence *, const QString &name );
00100 
00104     virtual bool processInput() { return false; }
00105 
00106     virtual void processCancel() {}
00107     
00108     void cancelRemovedAttendees( Incidence *incidence );
00109 
00110     Calendar *mCalendar;
00111 
00112     KPIM::CategorySelectDialog *mCategoryDialog;
00113 
00114     KOEditorDetails *mDetails;
00115     KOEditorAttachments *mAttachments;
00116 };
00117 
00118 #endif
00119 
00120 
KDE Logo
This file is part of the documentation for korganizer Library Version 3.3.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Mon Apr 4 04:49:27 2005 by doxygen 1.3.9.1 written by Dimitri van Heesch, © 1997-2003