summaryrefslogtreecommitdiff
path: root/core/pim/todo/templateeditor.cpp
authorzecke <zecke>2002-10-07 11:39:30 (UTC)
committer zecke <zecke>2002-10-07 11:39:30 (UTC)
commitf11d4bda64b58abfebf77485d5d77143a10dc8c9 (patch) (unidiff)
treea4e80550c4abe867303553de608316941dd943f1 /core/pim/todo/templateeditor.cpp
parentc2cd5470fa3ec69394fa65ad16ab29a6cadab56f (diff)
downloadopie-f11d4bda64b58abfebf77485d5d77143a10dc8c9.zip
opie-f11d4bda64b58abfebf77485d5d77143a10dc8c9.tar.gz
opie-f11d4bda64b58abfebf77485d5d77143a10dc8c9.tar.bz2
Re add files
for todo
Diffstat (limited to 'core/pim/todo/templateeditor.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/todo/templateeditor.cpp39
1 files changed, 39 insertions, 0 deletions
diff --git a/core/pim/todo/templateeditor.cpp b/core/pim/todo/templateeditor.cpp
new file mode 100644
index 0000000..1b52d4f
--- a/dev/null
+++ b/core/pim/todo/templateeditor.cpp
@@ -0,0 +1,39 @@
1#include <qaction.h>
2#include <qpopupmenu.h>
3
4#include "mainwindow.h"
5#include "todotemplatemanager.h"
6
7#include "templatedialogimpl.h"
8#include "templateeditor.h"
9
10using namespace Todo;
11
12TemplateEditor::TemplateEditor( MainWindow* main,
13 TemplateManager* manager )
14 : QObject( main ), m_main( main ), m_man( manager )
15{
16 init();
17
18}
19TemplateEditor::~TemplateEditor() {
20
21}
22/* ok we add us to the Menubar */
23void TemplateEditor::init() {
24 QAction* a = new QAction( QString::null, tr("Configure Templates"),
25 0, this, 0, FALSE );
26 connect(a, SIGNAL(activated() ),
27 this, SLOT(setUp() ) );
28
29 a->addTo( m_main->options() );
30}
31void TemplateEditor::setUp() {
32 qWarning("set up");
33 TemplateDialogImpl dlg(m_main, m_man );
34 int ret= dlg.exec();
35 if (QDialog::Accepted != ret ) {
36 m_man->load();
37 }else
38 m_main->populateTemplates();
39}