-rw-r--r-- | core/pim/osearch/todoitem.cpp | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/core/pim/osearch/todoitem.cpp b/core/pim/osearch/todoitem.cpp index 145b423..8b354f1 100644 --- a/core/pim/osearch/todoitem.cpp +++ b/core/pim/osearch/todoitem.cpp @@ -24,3 +24,2 @@ TodoItem::TodoItem(OListViewItem* parent, OTodo *todo) - TodoItem::~TodoItem() @@ -30,8 +29,2 @@ TodoItem::~TodoItem() - -void TodoItem::expand() -{ - ResultItem::expand(); -} - QString TodoItem::toRichText() @@ -41,14 +34,19 @@ QString TodoItem::toRichText() -void TodoItem::showItem() +void TodoItem::action( int act ) { -// QCopEnvelope e("QPE/Todolist", "show(int)"); + if (act == 0){ QCopEnvelope e("QPE/Application/todolist", "show(int)"); e << _todo->uid(); + }else if (act == 1){ + QCopEnvelope e("QPE/Application/todolist", "edit(int)"); + e << _todo->uid(); + } } -void TodoItem::editItem() +QIntDict<QString> TodoItem::actions() { -// QCopEnvelope e("QPE/Todolist", "edit(int)"); - QCopEnvelope e("QPE/Application/todolist", "edit(int)"); - e << _todo->uid(); + QIntDict<QString> result; + result.insert( 0, new QString( QObject::tr("show") ) ); + result.insert( 1, new QString( QObject::tr("edit") ) ); + return result; } |