Diffstat (limited to 'core/pim/todo/todoentryimpl.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/pim/todo/todoentryimpl.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/pim/todo/todoentryimpl.cpp b/core/pim/todo/todoentryimpl.cpp index 1dc1d44..f938d61 100644 --- a/core/pim/todo/todoentryimpl.cpp +++ b/core/pim/todo/todoentryimpl.cpp @@ -39,25 +39,25 @@ #include <qmultilineedit.h> #include <qlabel.h> #include <qtimer.h> #include <qapplication.h> NewTaskDialog::NewTaskDialog( const ToDoEvent& task, QWidget *parent, const char *name, bool modal, WFlags fl ) : NewTaskDialogBase( parent, name, modal, fl ), todo( task ) { qWarning("setting category" ); - todo.setCategory( task.category() ); + todo.setCategories( task.allCategories() ); if ( todo.hasDate() ) date = todo.date(); else date = QDate::currentDate(); init(); comboPriority->setCurrentItem( task.priority() - 1 ); checkCompleted->setChecked( task.isCompleted() ); checkDate->setChecked( task.hasDate() ); buttonDate->setText( TimeString::longDateString( date ) ); @@ -119,28 +119,28 @@ void NewTaskDialog::dateChanged( int y, int m, int d ) ToDoEvent NewTaskDialog::todoEntry() { qWarning("todoEntry()" ); if( checkDate->isChecked() ){ todo.setDate( date ); todo.setHasDate( true ); }else{ todo.setHasDate( false ); } qWarning("todoEntry::category()" ); if ( comboCategory->currentCategory() != -1 ) { QArray<int> arr = comboCategory->currentCategories(); - int id = arr[0]; - qWarning("id 0: %d",id ); - todo.setCategory( Qtopia::Record::idsToString( arr ) ); + QStringList list; + list = QStringList::split(";", Qtopia::Record::idsToString( arr )) ; qWarning("saving category"); + todo.setCategories( list ); } todo.setPriority( comboPriority->currentItem() + 1 ); todo.setCompleted( checkCompleted->isChecked() ); todo.setDescription( txtTodo->text() ); return todo; } /*! |