-rw-r--r-- | libopie2/opiepim/otodo.h | 26 |
1 files changed, 16 insertions, 10 deletions
diff --git a/libopie2/opiepim/otodo.h b/libopie2/opiepim/otodo.h index 429108a..e1729db 100644 --- a/libopie2/opiepim/otodo.h +++ b/libopie2/opiepim/otodo.h @@ -5,33 +5,33 @@ #include <qarray.h> #include <qmap.h> #include <qregexp.h> #include <qstringlist.h> #include <qdatetime.h> #include <qvaluelist.h> #include <qpe/recordfields.h> #include <qpe/palmtopuidgen.h> #include <opie/opimrecord.h> class OTodo : public OPimRecord { public: - typedef QValueList<ToDoEvent> ValueList; + typedef QValueList<OTodo> ValueList; enum RecordFields { Uid = Qtopia::UID_ID, Category = Qtopia::CATEGORY_ID, HasDate, Completed, Description, Summary, Priority, DateDay, DateMonth, DateYear, Progress, CrossReference, HasAlarmDateTime, AlarmDateTime }; @@ -105,32 +105,39 @@ public: /** * The description of the todo */ QString description()const; /** * A small summary of the todo */ QString summary() const; /** * @reimplemented * Return this todoevent in a RichText formatted QString */ QString toRichText() const; + /** + * reimplementation + */ + QString type()const; + QString toShortText()const; + QMap<QString, QString> toExtraMap()const; + QString recordField(int id )const; /** * returns a list of apps which have related items */ QStringList relatedApps()const; /** * returns all relations for one app */ QArray<int> relations( const QString& app )const; /** * toMap puts all data into the map. int relates * to ToDoEvent RecordFields enum */ QMap<int, QString> toMap()const; @@ -170,36 +177,35 @@ public: */ void setAlarmDateTime ( const QDateTime& alarm ); void setDescription(const QString& ); void setSummary(const QString& ); bool isOverdue(); bool match( const QRegExp &r )const; bool operator<(const OTodo &toDoEvent )const; bool operator<=(const OTodo &toDoEvent )const; bool operator!=(const OTodo &toDoEvent )const; bool operator>(const OTodo &toDoEvent )const; bool operator>=(const OTodo &toDoEvent)const; bool operator==(const OTodo &toDoEvent )const; - ToDoEvent &operator=(const OTodo &toDoEvent ); + OTodo &operator=(const OTodo &toDoEvent ); private: class OTodoPrivate; - struct OTodoEventData; + struct OTodoData; void deref(); void changeOrModify(); void copy( OTodoData* src, OTodoData* dest ); - ToDoEventPrivate *d; - ToDoEventData *data; + OTodoPrivate *d; + OTodoData *data; - static Qtopia::UidGen m_gen; -}; - inline bool ToDoEvent::operator!=(const ToDoEvent &toDoEvent )const { - return !(*this == toDoEvent); - } }; +inline bool OTodo::operator!=(const OTodo &toDoEvent )const { + return !(*this == toDoEvent); +} + #endif |