-rw-r--r-- | korganizer/kotodoeditor.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/korganizer/kotodoeditor.cpp b/korganizer/kotodoeditor.cpp index ec5c2d1..70dfbd1 100644 --- a/korganizer/kotodoeditor.cpp +++ b/korganizer/kotodoeditor.cpp @@ -260,51 +260,51 @@ void KOTodoEditor::deleteTodo() emit dialogClose(mTodo); mCalendar->deleteTodo(mTodo); emit todoDeleted(); reject(); } } else { reject(); } } void KOTodoEditor::setDefaults(QDateTime due,Todo *relatedEvent,bool allDay) { mRelatedTodo = relatedEvent; mGeneral->setDefaults(due,allDay); mDetails->setDefaults(); showPage( 0 ); if ( mRelatedTodo ) { mGeneral->setCategories (mRelatedTodo->categoriesStr ()); mGeneral->setSecrecy (mRelatedTodo->secrecy ()); if ( mRelatedTodo->priority() < 3 ) mGeneral->mPriorityCombo->setCurrentItem(mRelatedTodo->priority()-1); mGeneral->mSummaryEdit->lineEdit()->setText(mRelatedTodo->summary()+": "); int len = mRelatedTodo->summary().length(); - mGeneral->mSummaryEdit->lineEdit()->setSelection ( 0, len+2 ); - mGeneral->mSummaryEdit->lineEdit()->setCursorPosition ( len+2 ); mGeneral->mSummaryEdit->lineEdit()->setFocus(); + mGeneral->mSummaryEdit->lineEdit()->setCursorPosition ( len+2 ); + mGeneral->mSummaryEdit->lineEdit()->setSelection ( 0, len+2 ); } else mGeneral->setFocusOn( 2 ); } void KOTodoEditor::readTodo(Todo *todo) { mGeneral->readTodo(todo); mDetails->readEvent(todo); mRelatedTodo = 0;//todo->relatedTo(); // categories // mCategoryDialog->setSelected(todo->categories()); // We should handle read-only events here. } void KOTodoEditor::writeTodo(Todo *event) { mGeneral->writeTodo(event); mDetails->writeEvent(event); // set related event, i.e. parent to-do in this case. if (mRelatedTodo) { event->setRelatedTo(mRelatedTodo); |