summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/todo/mainwindow.cpp1
1 files changed, 0 insertions, 1 deletions
diff --git a/core/pim/todo/mainwindow.cpp b/core/pim/todo/mainwindow.cpp
index bf9fc23..71e6750 100644
--- a/core/pim/todo/mainwindow.cpp
+++ b/core/pim/todo/mainwindow.cpp
@@ -4,97 +4,96 @@
4           .>+-= 4           .>+-=
5 _;:,     .>    :=|. This program is free software; you can 5 _;:,     .>    :=|. This program is free software; you can
6.> <`_,   >  .   <= redistribute it and/or modify it under 6.> <`_,   >  .   <= redistribute it and/or modify it under
7:`=1 )Y*s>-.--   : the terms of the GNU General Public 7:`=1 )Y*s>-.--   : the terms of the GNU General Public
8.="- .-=="i,     .._ License as published by the Free Software 8.="- .-=="i,     .._ License as published by the Free Software
9 - .   .-<_>     .<> Foundation; either version 2 of the License, 9 - .   .-<_>     .<> Foundation; either version 2 of the License,
10     ._= =}       : or (at your option) any later version. 10     ._= =}       : or (at your option) any later version.
11    .%`+i>       _;_. 11    .%`+i>       _;_.
12    .i_,=:_.      -<s. This program is distributed in the hope that 12    .i_,=:_.      -<s. This program is distributed in the hope that
13     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY; 13     +  .  -:.       = it will be useful, but WITHOUT ANY WARRANTY;
14    : ..    .:,     . . . without even the implied warranty of 14    : ..    .:,     . . . without even the implied warranty of
15    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A 15    =_        +     =;=|` MERCHANTABILITY or FITNESS FOR A
16  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU 16  _.=:.       :    :=>`: PARTICULAR PURPOSE. See the GNU
17..}^=.=       =       ; Library General Public License for more 17..}^=.=       =       ; Library General Public License for more
18++=   -.     .`     .: details. 18++=   -.     .`     .: details.
19 :     =  ...= . :.=- 19 :     =  ...= . :.=-
20 -.   .:....=;==+<; You should have received a copy of the GNU 20 -.   .:....=;==+<; You should have received a copy of the GNU
21  -_. . .   )=.  = General Public License along with 21  -_. . .   )=.  = General Public License along with
22    --        :-=` this library; see the file COPYING.LIB. 22    --        :-=` this library; see the file COPYING.LIB.
23 If not, write to the Free Software Foundation, 23 If not, write to the Free Software Foundation,
24 Inc., 59 Temple Place - Suite 330, 24 Inc., 59 Temple Place - Suite 330,
25 Boston, MA 02111-1307, USA. 25 Boston, MA 02111-1307, USA.
26 26
27*/ 27*/
28 28
29#include <unistd.h> 29#include <unistd.h>
30 30
31#include <qmenubar.h> 31#include <qmenubar.h>
32#include <qmessagebox.h> 32#include <qmessagebox.h>
33#include <qtoolbar.h> 33#include <qtoolbar.h>
34#include <qpopupmenu.h> 34#include <qpopupmenu.h>
35#include <qwidgetstack.h> 35#include <qwidgetstack.h>
36#include <qaction.h> 36#include <qaction.h>
37#include <qtimer.h> 37#include <qtimer.h>
38#include <qvbox.h> 38#include <qvbox.h>
39#include <qlineedit.h> 39#include <qlineedit.h>
40 40
41#include <qpe/applnk.h> 41#include <qpe/applnk.h>
42#include <qpe/config.h> 42#include <qpe/config.h>
43#include <qpe/ir.h> 43#include <qpe/ir.h>
44#include <qpe/resource.h> 44#include <qpe/resource.h>
45#include <qpe/qpemessagebox.h> 45#include <qpe/qpemessagebox.h>
46 46
47#include <opie/otodoaccessvcal.h> 47#include <opie/otodoaccessvcal.h>
48 48
49#include "quickeditimpl.h" 49#include "quickeditimpl.h"
50#include "todotemplatemanager.h" 50#include "todotemplatemanager.h"
51#include "templateeditor.h" 51#include "templateeditor.h"
52#include "todoentryimpl.h"
53#include "tableview.h" 52#include "tableview.h"
54 53
55#include "textviewshow.h" 54#include "textviewshow.h"
56#include "todoeditor.h" 55#include "todoeditor.h"
57#include "mainwindow.h" 56#include "mainwindow.h"
58 57
59 58
60using namespace Todo; 59using namespace Todo;
61 60
62MainWindow::MainWindow( QWidget* parent, 61MainWindow::MainWindow( QWidget* parent,
63 const char* name ) { 62 const char* name ) {
64 63
65 m_syncing = false; 64 m_syncing = false;
66 m_counter = 0; 65 m_counter = 0;
67 m_tempManager = new TemplateManager(); 66 m_tempManager = new TemplateManager();
68 m_tempManager->load(); 67 m_tempManager->load();
69 68
70 initUI(); 69 initUI();
71 initConfig(); 70 initConfig();
72 initViews(); 71 initViews();
73 initActions(); 72 initActions();
74 initEditor(); 73 initEditor();
75 initShow(); 74 initShow();
76 initTemplate(); 75 initTemplate();
77 76
78 populateTemplates(); 77 populateTemplates();
79 raiseCurrentView(); 78 raiseCurrentView();
80 QTimer::singleShot(0, this, SLOT(populateCategories() ) ); 79 QTimer::singleShot(0, this, SLOT(populateCategories() ) );
81} 80}
82void MainWindow::initTemplate() { 81void MainWindow::initTemplate() {
83 m_curTempEd = new TemplateEditor( this, templateManager() ); 82 m_curTempEd = new TemplateEditor( this, templateManager() );
84} 83}
85void MainWindow::initActions() { 84void MainWindow::initActions() {
86 QAction* a = new QAction( tr("New Task" ), Resource::loadPixmap( "new" ), 85 QAction* a = new QAction( tr("New Task" ), Resource::loadPixmap( "new" ),
87 QString::null, 0, this, 0 ); 86 QString::null, 0, this, 0 );
88 connect(a, SIGNAL( activated() ), 87 connect(a, SIGNAL( activated() ),
89 this, SLOT( slotNew() ) ); 88 this, SLOT( slotNew() ) );
90 a->addTo(m_tool ); 89 a->addTo(m_tool );
91 a->addTo(m_edit ); 90 a->addTo(m_edit );
92 91
93 a = new QAction( tr("Edit Task"), Resource::loadIconSet( "edit" ), 92 a = new QAction( tr("Edit Task"), Resource::loadIconSet( "edit" ),
94 QString::null, 0, this, 0 ); 93 QString::null, 0, this, 0 );
95 connect(a, SIGNAL(activated() ), 94 connect(a, SIGNAL(activated() ),
96 this, SLOT( slotEdit() ) ); 95 this, SLOT( slotEdit() ) );
97 a->addTo( m_tool ); 96 a->addTo( m_tool );
98 a->addTo( m_edit ); 97 a->addTo( m_edit );
99 m_editAction = a; 98 m_editAction = a;
100 99