equal
deleted
inserted
replaced
27 #include <QSharedData> |
27 #include <QSharedData> |
28 #include <QTextDocument> |
28 #include <QTextDocument> |
29 #include <smfclientglobal.h> |
29 #include <smfclientglobal.h> |
30 |
30 |
31 #include "smfpost_p.h" |
31 #include "smfpost_p.h" |
32 |
32 const int MaxSmfPostSize=1000; |
33 /** |
33 /** |
34 * Presence info of the user |
34 * Presence info of the user |
35 */ |
35 */ |
36 enum SmfAppearenceInfo |
36 enum SmfAppearenceInfo |
37 { |
37 { |
58 */ |
58 */ |
59 SmfPost( ); |
59 SmfPost( ); |
60 |
60 |
61 /** |
61 /** |
62 * Constructor |
62 * Constructor |
|
63 * @param aOwner Owner of the post(who posted this message) of type SmfContact |
63 * @param aText The post's text |
64 * @param aText The post's text |
64 * @param aImage The post's image |
65 * @param aImage The post's image |
65 * @param aUrl The post's url |
66 * @param aUrl The post's url |
66 */ |
67 */ |
67 SmfPost( QString aTitle, QString aDesc, QImage aImage, QUrl aUrl ); |
68 SmfPost(SmfContact aOwner, QString aTitle, QString aDesc, QImage aImage, QUrl aUrl ); |
68 |
69 |
69 /** |
70 /** |
70 * Copy Constructor |
71 * Copy Constructor |
71 * @param aOther The reference object |
72 * @param aOther The reference object |
72 */ |
73 */ |
81 |
82 |
82 /** |
83 /** |
83 * Destructor |
84 * Destructor |
84 */ |
85 */ |
85 ~SmfPost( ); |
86 ~SmfPost( ); |
86 |
87 /** |
|
88 * Returns the owner(who posted this message) |
|
89 */ |
|
90 SmfContact owner() const; |
87 /** |
91 /** |
88 * Method to get the title of the post |
92 * Method to get the title of the post |
89 * @return The post's title |
93 * @return The post's title |
90 */ |
94 */ |
91 QString title( ) const; |
95 QString title( ) const; |
111 /** |
115 /** |
112 * Method to get the id of the post |
116 * Method to get the id of the post |
113 * @return The ID value |
117 * @return The ID value |
114 */ |
118 */ |
115 QString id( ) const; |
119 QString id( ) const; |
116 |
120 /** |
|
121 * sets the owner of the post |
|
122 */ |
|
123 void setOwner(const SmfContact& aOwner); |
117 /** |
124 /** |
118 * Method to set the title of the post |
125 * Method to set the title of the post |
119 * @param aTitle The post's new title |
126 * @param aTitle The post's new title |
120 */ |
127 */ |
121 void setTitle( const QString &aTitle ); |
128 void setTitle( const QString &aTitle ); |
176 |
183 |
177 typedef QList<SmfPost> SmfPostList; |
184 typedef QList<SmfPost> SmfPostList; |
178 |
185 |
179 // Make the class SmfPost known to QMetaType, so that as to register it. |
186 // Make the class SmfPost known to QMetaType, so that as to register it. |
180 Q_DECLARE_METATYPE(SmfPost) |
187 Q_DECLARE_METATYPE(SmfPost) |
181 Q_DECLARE_METATYPE(QList<SmfPost>) |
188 Q_DECLARE_METATYPE(SmfPostList) |
182 |
189 |
183 #endif /* SMFPOST_H_ */ |
190 #endif /* SMFPOST_H_ */ |