summaryrefslogtreecommitdiff
authorzecke <zecke>2003-09-06 06:31:13 (UTC)
committer zecke <zecke>2003-09-06 06:31:13 (UTC)
commite06de75edc6c01d97248050030f197bd8f21fb10 (patch) (side-by-side diff)
tree4696ac60c9cdb5fc80c28c862eb856c64b7b7c8c
parenteaf6da2bd05eac392c118c11fd5be1bab8586b6a (diff)
downloadopie-e06de75edc6c01d97248050030f197bd8f21fb10.zip
opie-e06de75edc6c01d97248050030f197bd8f21fb10.tar.gz
opie-e06de75edc6c01d97248050030f197bd8f21fb10.tar.bz2
-Switch to OWidgetStack actually only three lines touch by this
-the really quit on closeEvent and don't wait for the last window -use setName eases debugging
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/pim/todo/mainwindow.cpp7
-rw-r--r--core/pim/todo/mainwindow.h4
-rw-r--r--core/pim/todo/tableview.cpp1
3 files changed, 9 insertions, 3 deletions
diff --git a/core/pim/todo/mainwindow.cpp b/core/pim/todo/mainwindow.cpp
index ecb4e40..ad7899f 100644
--- a/core/pim/todo/mainwindow.cpp
+++ b/core/pim/todo/mainwindow.cpp
@@ -52,8 +52,9 @@
#include <opie/orecur.h>
#include <opie/opimnotifymanager.h>
#include <opie/otodoaccessvcal.h>
+#include <opie/owidgetstack.h>
#include <opie/oapplicationfactory.h>
#include "quickeditimpl.h"
@@ -72,8 +73,11 @@ using namespace Todo;
MainWindow::MainWindow( QWidget* parent,
const char* name, WFlags )
: OPimMainWindow( "Todolist", parent, name, WType_TopLevel | WStyle_ContextHelp )
{
+ if (!name)
+ setName("todo window");
+
m_syncing = false;
m_showing = false;
m_counter = 0;
m_tempManager = new TemplateManager();
@@ -223,9 +227,9 @@ void MainWindow::initConfig() {
m_quicktask = config.readBoolEntry("ShowQuickTask", TRUE);
}
void MainWindow::initUI() {
- m_stack = new QWidgetStack(this, "main stack");
+ m_stack = new OWidgetStack(this, "main stack");
setCentralWidget( m_stack );
setToolBarsMovable( FALSE );
@@ -404,8 +408,9 @@ void MainWindow::closeEvent( QCloseEvent* e ) {
config.writeEntry( "ShowQuickTask", showQuickTask() );
/* save templates */
templateManager()->save();
e->accept();
+ qApp->quit();
}
}
void MainWindow::populateTemplates() {
m_template->clear();
diff --git a/core/pim/todo/mainwindow.h b/core/pim/todo/mainwindow.h
index bd341c2..fd0e1bd 100644
--- a/core/pim/todo/mainwindow.h
+++ b/core/pim/todo/mainwindow.h
@@ -43,9 +43,9 @@
class QPopupMenu;
class QMenuBar;
class QToolBar;
class QAction;
-class QWidgetStack;
+class OWidgetStack;
class Ir;
class QVBox;
class QLineEdit;
@@ -141,9 +141,9 @@ private slots:
*m_duplicateAction,
*m_showOverDueAction,
*m_showQuickTaskAction,
*m_effectiveAction;
- QWidgetStack *m_stack;
+ OWidgetStack *m_stack;
QPopupMenu* m_catMenu,
*m_edit,
*m_options,
*m_template;
diff --git a/core/pim/todo/tableview.cpp b/core/pim/todo/tableview.cpp
index 2e252d5..def0efb 100644
--- a/core/pim/todo/tableview.cpp
+++ b/core/pim/todo/tableview.cpp
@@ -84,8 +84,9 @@ void TableView::initConfig() {
TableView::TableView( MainWindow* window, QWidget* wid )
: QTable( wid ), TodoView( window ) {
+ setName("TableView");
// Load icons
// TODO - probably should be done globally somewhere else,
// see also quickeditimpl.cpp/h, taskeditoroverview.cpp/h
m_pic_completed = Resource::loadPixmap( "todo/completed" );