-rw-r--r-- | korganizer/kotodoview.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/korganizer/kotodoview.cpp b/korganizer/kotodoview.cpp index 1a1bce5..3011458 100644 --- a/korganizer/kotodoview.cpp +++ b/korganizer/kotodoview.cpp | |||
@@ -963,2 +963,3 @@ void KOTodoView::changedCategories(int index) | |||
963 | QStringList categories = mActiveItem->todo()->categories (); | 963 | QStringList categories = mActiveItem->todo()->categories (); |
964 | QString colcat = categories.first(); | ||
964 | if (categories.find (mCategory[index]) != categories.end ()) | 965 | if (categories.find (mCategory[index]) != categories.end ()) |
@@ -968,2 +969,8 @@ void KOTodoView::changedCategories(int index) | |||
968 | categories.sort (); | 969 | categories.sort (); |
970 | if ( !colcat.isEmpty() ) { | ||
971 | if ( categories.find ( colcat ) != categories.end () ) { | ||
972 | categories.remove( colcat ); | ||
973 | categories.prepend( colcat ); | ||
974 | } | ||
975 | } | ||
969 | mActiveItem->todo()->setCategories (categories); | 976 | mActiveItem->todo()->setCategories (categories); |