summaryrefslogtreecommitdiffabout
path: root/korganizer/kotodoeditor.cpp
Unidiff
Diffstat (limited to 'korganizer/kotodoeditor.cpp') (more/less context) (show whitespace changes)
-rw-r--r--korganizer/kotodoeditor.cpp1
1 files changed, 0 insertions, 1 deletions
diff --git a/korganizer/kotodoeditor.cpp b/korganizer/kotodoeditor.cpp
index 1c44f2b..abeb068 100644
--- a/korganizer/kotodoeditor.cpp
+++ b/korganizer/kotodoeditor.cpp
@@ -2,97 +2,96 @@
2 This file is part of KOrganizer. 2 This file is part of KOrganizer.
3 Copyright (c) 1997, 1998 Preston Brown 3 Copyright (c) 1997, 1998 Preston Brown
4 Copyright (c) 2000,2001 Cornelius Schumacher <schumacher@kde.org> 4 Copyright (c) 2000,2001 Cornelius Schumacher <schumacher@kde.org>
5 5
6 This program is free software; you can redistribute it and/or modify 6 This program is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by 7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or 8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version. 9 (at your option) any later version.
10 10
11 This program is distributed in the hope that it will be useful, 11 This program is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of 12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details. 14 GNU General Public License for more details.
15 15
16 You should have received a copy of the GNU General Public License 16 You should have received a copy of the GNU General Public License
17 along with this program; if not, write to the Free Software 17 along with this program; if not, write to the Free Software
18 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 18 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
19 19
20 As a special exception, permission is given to link this program 20 As a special exception, permission is given to link this program
21 with any edition of Qt, and distribute the resulting executable, 21 with any edition of Qt, and distribute the resulting executable,
22 without including the source code for Qt in the source distribution. 22 without including the source code for Qt in the source distribution.
23*/ 23*/
24 24
25#include <qtooltip.h> 25#include <qtooltip.h>
26#include <qframe.h> 26#include <qframe.h>
27#include <qpixmap.h> 27#include <qpixmap.h>
28#include <qlayout.h> 28#include <qlayout.h>
29#include <qhbox.h> 29#include <qhbox.h>
30#include <qdir.h> 30#include <qdir.h>
31#include <qdatetime.h> 31#include <qdatetime.h>
32#include <qapplication.h> 32#include <qapplication.h>
33 33
34#include <kiconloader.h> 34#include <kiconloader.h>
35#include <klocale.h> 35#include <klocale.h>
36#include <kfiledialog.h> 36#include <kfiledialog.h>
37#include <kstandarddirs.h> 37#include <kstandarddirs.h>
38#include <kmessagebox.h> 38#include <kmessagebox.h>
39 39
40#include <libkdepim/categoryselectdialog.h> 40#include <libkdepim/categoryselectdialog.h>
41#include <libkcal/calendarlocal.h> 41#include <libkcal/calendarlocal.h>
42#include <libkcal/calendarresources.h> 42#include <libkcal/calendarresources.h>
43#include <libkcal/resourcecalendar.h> 43#include <libkcal/resourcecalendar.h>
44#include <libkcal/icalformat.h> 44#include <libkcal/icalformat.h>
45#include <kresources/resourceselectdialog.h> 45#include <kresources/resourceselectdialog.h>
46 46
47#include "koprefs.h" 47#include "koprefs.h"
48 48
49#include "kotodoeditor.h" 49#include "kotodoeditor.h"
50#include "kotodoeditor.moc"
51extern int globalFlagBlockAgenda; 50extern int globalFlagBlockAgenda;
52 51
53KOTodoEditor::KOTodoEditor( Calendar *calendar, QWidget *parent ) : 52KOTodoEditor::KOTodoEditor( Calendar *calendar, QWidget *parent ) :
54 KOIncidenceEditor( i18n("Edit To-Do"), calendar, parent ) 53 KOIncidenceEditor( i18n("Edit To-Do"), calendar, parent )
55{ 54{
56 mTodo = 0; 55 mTodo = 0;
57 mRelatedTodo = 0; 56 mRelatedTodo = 0;
58 findButton(User1)->hide(); 57 findButton(User1)->hide();
59 init(); 58 init();
60} 59}
61 60
62KOTodoEditor::~KOTodoEditor() 61KOTodoEditor::~KOTodoEditor()
63{ 62{
64 emit dialogClose( mTodo ); 63 emit dialogClose( mTodo );
65} 64}
66 65
67void KOTodoEditor::init() 66void KOTodoEditor::init()
68{ 67{
69 setupGeneral(); 68 setupGeneral();
70 setupAttendeesTab(); 69 setupAttendeesTab();
71} 70}
72void KOTodoEditor::setCategories( QString s ) 71void KOTodoEditor::setCategories( QString s )
73{ 72{
74 mGeneral->setCategories(s); 73 mGeneral->setCategories(s);
75} 74}
76void KOTodoEditor::setSecrecy( int sec ) 75void KOTodoEditor::setSecrecy( int sec )
77{ 76{
78 mGeneral->setSecrecy( sec ); 77 mGeneral->setSecrecy( sec );
79} 78}
80void KOTodoEditor::reload() 79void KOTodoEditor::reload()
81{ 80{
82 if ( mTodo ) readTodo( mTodo ); 81 if ( mTodo ) readTodo( mTodo );
83} 82}
84 83
85void KOTodoEditor::setupGeneral() 84void KOTodoEditor::setupGeneral()
86{ 85{
87 mGeneral = new KOEditorGeneralTodo(this); 86 mGeneral = new KOEditorGeneralTodo(this);
88 connect ( mGeneral, SIGNAL ( allAccepted() ), this, SLOT ( slotOk () ) ); 87 connect ( mGeneral, SIGNAL ( allAccepted() ), this, SLOT ( slotOk () ) );
89 88
90 // connect(mGeneral,SIGNAL(openCategoryDialog()),mCategoryDialog,SLOT(show())); 89 // connect(mGeneral,SIGNAL(openCategoryDialog()),mCategoryDialog,SLOT(show()));
91 //connect(mCategoryDialog, SIGNAL(categoriesSelected(const QString &)), 90 //connect(mCategoryDialog, SIGNAL(categoriesSelected(const QString &)),
92 // mGeneral,SLOT(setCategories(const QString &))); 91 // mGeneral,SLOT(setCategories(const QString &)));
93 92
94 if (KOPrefs::instance()->mCompactDialogs) { 93 if (KOPrefs::instance()->mCompactDialogs) {
95 QFrame *topFrame = addPage(i18n("General")); 94 QFrame *topFrame = addPage(i18n("General"));
96 95
97 QBoxLayout *topLayout = new QVBoxLayout(topFrame); 96 QBoxLayout *topLayout = new QVBoxLayout(topFrame);
98 if ( QApplication::desktop()->width() < 480 ) { 97 if ( QApplication::desktop()->width() < 480 ) {