author | tille <tille> | 2003-05-11 19:19:30 (UTC) |
---|---|---|
committer | tille <tille> | 2003-05-11 19:19:30 (UTC) |
commit | 43c18630840a98aed8deb96b454957c40f0a4344 (patch) (unidiff) | |
tree | 60e5b68d1d172c77560d5af7bea83e81be7144a6 /core/pim/osearch/eventitem.cpp | |
parent | 38dc2fd6258f11ba0507c7bd8f8dfd5b39bc0df5 (diff) | |
download | opie-43c18630840a98aed8deb96b454957c40f0a4344.zip opie-43c18630840a98aed8deb96b454957c40f0a4344.tar.gz opie-43c18630840a98aed8deb96b454957c40f0a4344.tar.bz2 |
improved applnk and doclnk searching
clean up:
- mainwindow: handling of searchgroups
- searchgroups: introduced load, search and insertItem functions
- flexible actions handling
- doclnksearch inherits applnksearch
Diffstat (limited to 'core/pim/osearch/eventitem.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | core/pim/osearch/eventitem.cpp | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/core/pim/osearch/eventitem.cpp b/core/pim/osearch/eventitem.cpp index 758ad85..3b84b42 100644 --- a/core/pim/osearch/eventitem.cpp +++ b/core/pim/osearch/eventitem.cpp | |||
@@ -34,17 +34,21 @@ QString EventItem::toRichText() | |||
34 | return _event->toRichText(); | 34 | return _event->toRichText(); |
35 | } | 35 | } |
36 | 36 | ||
37 | void EventItem::editItem() | 37 | void EventItem::action( int act ) |
38 | { | 38 | { |
39 | QCopEnvelope e("QPE/Application/datebook", "editEvent(int)"); | 39 | if (act == 0){ |
40 | e << _event->uid(); | 40 | QCopEnvelope e("QPE/Application/datebook", "viewDefault(QDate)"); |
41 | e << _event->startDateTime().date(); | ||
42 | }else if(act == 1){ | ||
43 | QCopEnvelope e("QPE/Application/datebook", "editEvent(int)"); | ||
44 | e << _event->uid(); | ||
45 | } | ||
41 | } | 46 | } |
42 | 47 | ||
43 | void EventItem::showItem() | 48 | QIntDict<QString> EventItem::actions() |
44 | { | 49 | { |
45 | QCopEnvelope e("QPE/Application/datebook", "viewDefault(QDate)"); | 50 | QIntDict<QString> result; |
46 | QDate day = _event->startDateTime().date(); | 51 | result.insert( 0, new QString( QObject::tr("show") ) ); |
47 | qDebug("sending view day %s",day.toString().latin1()); | 52 | result.insert( 1, new QString( QObject::tr("edit") ) ); |
48 | e << day; | 53 | return result; |
49 | } | 54 | } |
50 | |||