diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2002-04-17 10:16:58 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2002-04-17 10:16:58 +0800 |
commit | 91259ad3c04665082bbac0f2dbc073e008b3c957 (patch) | |
tree | 8b4f3d844bb6adfd703b777e96fe3877871c1331 /composer/e-msg-composer.c | |
parent | fc281a966c29421c896746d784a6f1393fe37f3f (diff) | |
download | gsoc2013-evolution-91259ad3c04665082bbac0f2dbc073e008b3c957.tar.gz gsoc2013-evolution-91259ad3c04665082bbac0f2dbc073e008b3c957.tar.zst gsoc2013-evolution-91259ad3c04665082bbac0f2dbc073e008b3c957.zip |
Unref the priv->tooltips object here.
2002-04-16 Jeffrey Stedfast <fejj@ximian.com>
* e-msg-composer-hdrs.c (destroy): Unref the priv->tooltips object
here.
* e-msg-composer-attachment-bar.c (destroy): Free the priv struct.
* e-msg-composer.c (set_editor_signature): We don't need a 'name'?
So don't strdup it.
svn path=/trunk/; revision=16485
Diffstat (limited to 'composer/e-msg-composer.c')
-rw-r--r-- | composer/e-msg-composer.c | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/composer/e-msg-composer.c b/composer/e-msg-composer.c index 9aad5b863f..178b867004 100644 --- a/composer/e-msg-composer.c +++ b/composer/e-msg-composer.c @@ -881,6 +881,7 @@ set_editor_text (EMsgComposer *composer, const char *text) BonoboStream *stream; BonoboWidget *editor; CORBA_Environment ev; + Bonobo_Unknown object; g_return_if_fail (composer->persist_stream_interface != CORBA_OBJECT_NIL); @@ -891,10 +892,12 @@ set_editor_text (EMsgComposer *composer, const char *text) CORBA_exception_init (&ev); stream = bonobo_stream_mem_create (text, strlen (text), TRUE, FALSE); - Bonobo_PersistStream_load (persist, (Bonobo_Stream)bonobo_object_corba_objref (BONOBO_OBJECT (stream)), - "text/html", &ev); + object = bonobo_object_corba_objref (BONOBO_OBJECT (stream)); + Bonobo_PersistStream_load (persist, (Bonobo_Stream) object, "text/html", &ev); if (ev._major != CORBA_NO_EXCEPTION) { /* FIXME. Some error message. */ + bonobo_object_unref (BONOBO_OBJECT (stream)); + CORBA_exception_free (&ev); return; } @@ -2596,14 +2599,14 @@ map_default_cb (EMsgComposer *composer, gpointer user_data) pb = bonobo_control_frame_get_control_property_bag (cf, NULL); text = bonobo_property_bag_client_get_value_string (pb, "text", NULL); bonobo_object_release_unref (pb, NULL); - + if (!text || text[0] == '\0') { bonobo_control_frame_focus_child (cf, GTK_DIR_TAB_FORWARD); g_free (text); return; } g_free (text); - + /* If not, check the subject field */ text = e_msg_composer_hdrs_get_subject (E_MSG_COMPOSER_HDRS (composer->hdrs)); @@ -2761,26 +2764,24 @@ set_editor_signature (EMsgComposer *composer) printf ("set_editor_signature\n"); if (E_MSG_COMPOSER_HDRS (composer->hdrs)->account->id) { MailConfigIdentity *id; - gchar *verb, *name; + char *verb; id = E_MSG_COMPOSER_HDRS (composer->hdrs)->account->id; - + composer->random_signature = composer->send_html ? id->html_random : id->text_random; if (composer->random_signature) composer->signature = NULL; else composer->signature = composer->send_html ? id->html_signature : id->text_signature; - + if (composer->random_signature) { verb = g_strdup ("/commands/SignatureRandom"); - name = g_strdup ("SignatureRandom"); } else if (composer->signature == NULL) { verb = g_strdup ("/commands/SignatureNone"); - name = g_strdup ("SignatureNone"); } else { verb = g_strdup_printf ("/commands/Signature%d", composer->signature->id); - name = g_strdup_printf ("Signature%d", composer->signature->id); } + bonobo_ui_component_set_prop (composer->uic, verb, "state", "1", NULL); g_free (verb); } |