Changeset 3631
- Timestamp:
- 04/25/08 13:35:39
- Files:
-
- trunk/ChangeLog (modified) (1 diff)
- trunk/libtinymail-camel/tny-camel-transport-account-priv.h (modified) (1 diff)
- trunk/libtinymail-camel/tny-camel-transport-account.c (modified) (4 diffs)
- trunk/libtinymail-camel/tny-camel-transport-account.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/ChangeLog
r3630 r3631 3 3 * Error reporting when sending a message without From, and a crash-fix 4 4 about it too 5 * Added tny_camel_transport_account_get_from and 6 tny_camel_transport_account_set_from 7 8 * This was a minor API change 5 9 6 10 2008-04-24 Philip Van Hoof <pvanhoof@gnome.org> trunk/libtinymail-camel/tny-camel-transport-account-priv.h
r2825 r3631 25 25 struct _TnyCamelTransportAccountPriv 26 26 { 27 int i;27 gchar *from; 28 28 }; 29 29 trunk/libtinymail-camel/tny-camel-transport-account.c
r3630 r3631 264 264 } 265 265 266 /** 267 * tny_camel_transport_account_get_from: 268 * @self: a #TnyTransportAccount 269 * 270 * Get the from of @self. Returned value must not be freed. 271 * 272 * returns: (null-ok): a read-only string 273 **/ 274 const gchar * 275 tny_camel_transport_account_get_from (TnyTransportAccount *self) 276 { 277 TnyCamelTransportAccountPriv *priv = TNY_CAMEL_TRANSPORT_ACCOUNT_GET_PRIVATE (self); 278 return priv->from; 279 } 280 281 /** 282 * tny_camel_transport_account_set_from: 283 * @self: a #TnyTransportAccount 284 * @from: (null-ok): a string or NULL 285 * 286 * Set the from of @self. 287 **/ 288 void 289 tny_camel_transport_account_set_from (TnyTransportAccount *self, const gchar *from) 290 { 291 TnyCamelTransportAccountPriv *priv = TNY_CAMEL_TRANSPORT_ACCOUNT_GET_PRIVATE (self); 292 if (priv->from) 293 g_free (priv->from); 294 priv->from = g_strdup (from); 295 } 266 296 267 297 /** … … 270 300 * Create a new #TnyTransportAccount instance implemented for Camel 271 301 * 272 * Return value: A new #TnyTransportAccount instance implemented for Camel302 * returns: (caller-owns): A new #TnyTransportAccount instance implemented for Camel 273 303 **/ 274 304 TnyTransportAccount* … … 285 315 TnyCamelTransportAccount *self = (TnyCamelTransportAccount *)instance; 286 316 TnyCamelAccountPriv *apriv = TNY_CAMEL_ACCOUNT_GET_PRIVATE (self); 287 317 TnyCamelTransportAccountPriv *priv = TNY_CAMEL_TRANSPORT_ACCOUNT_GET_PRIVATE (self); 318 319 priv->from = NULL; 288 320 apriv->service = NULL; 289 321 apriv->type = CAMEL_PROVIDER_TRANSPORT; … … 301 333 tny_camel_transport_account_finalize (GObject *object) 302 334 { 335 TnyCamelTransportAccountPriv *priv = TNY_CAMEL_TRANSPORT_ACCOUNT_GET_PRIVATE (object); 336 337 if (priv->from) 338 g_free (priv->from); 339 303 340 (*parent_class->finalize) (object); 304 341 trunk/libtinymail-camel/tny-camel-transport-account.h
r3304 r3631 55 55 TnyTransportAccount* tny_camel_transport_account_new (void); 56 56 57 const gchar *tny_camel_transport_account_get_from (TnyTransportAccount *self); 58 void tny_camel_transport_account_set_from (TnyTransportAccount *self, const gchar *from); 59 57 60 G_END_DECLS 58 61
