summaryrefslogtreecommitdiffabout
path: root/korganizer/kotodoview.cpp
Side-by-side diff
Diffstat (limited to 'korganizer/kotodoview.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/kotodoview.cpp21
1 files changed, 13 insertions, 8 deletions
diff --git a/korganizer/kotodoview.cpp b/korganizer/kotodoview.cpp
index 03a8f1c..1a1bce5 100644
--- a/korganizer/kotodoview.cpp
+++ b/korganizer/kotodoview.cpp
@@ -593,13 +593,13 @@ void KOTodoView::updateView()
if ( !isVisible() ) {
mPendingUpdateBeforeRepaint = true;
return;
}
//qDebug("KOTodoView::updateView() %x", this);
if ( isFlatDisplay ) {
- setAllFlat();
+ displayAllFlat();
return;
}
//qDebug("update ");
// kdDebug() << "KOTodoView::updateView()" << endl;
QFont fo = KOPrefs::instance()->mTodoViewFont;
mTodoListView->clear();
@@ -1120,20 +1120,14 @@ void KOTodoView::setOpen( QListViewItem* item, bool setOpenI)
setOpen( item->firstChild(), setOpenI );
item->setOpen( setOpenI );
item = item->nextSibling();
}
}
-void KOTodoView::setAllFlat()
+void KOTodoView::displayAllFlat()
{
- if ( isFlatDisplay ) {
- isFlatDisplay = false;
- mPopupMenu->setItemChecked( 8,false );
- updateView();
- return;
- }
pendingSubtodo = 0;
if ( mBlockUpdate ) {
return;
}
mPopupMenu->setItemChecked( 8,true );
isFlatDisplay = true;
@@ -1146,12 +1140,23 @@ void KOTodoView::setAllFlat()
mTodoMap.insert(todo,todoItem);
}
mTodoListView->setFocus();
processSelectionChange();
}
+void KOTodoView::setAllFlat()
+{
+ if ( isFlatDisplay ) {
+ isFlatDisplay = false;
+ mPopupMenu->setItemChecked( 8,false );
+ updateView();
+ return;
+ }
+ displayAllFlat();
+}
+
void KOTodoView::purgeCompleted()
{
emit purgeCompletedSignal();
}
void KOTodoView::toggleQuickTodo()
{