[pkg-otr-team] [irssi-plugin-otr] 164/167: Correct the last call to dialog_update_label_conv

Holger Levsen holger at moszumanska.debian.org
Mon Mar 3 21:55:42 UTC 2014


This is an automated email from the git hooks/post-receive script.

holger pushed a commit to tag 4.0.0
in repository irssi-plugin-otr.

commit 263c938178a9052f0f907059ae30305c37809869
Author: Ian Goldberg <iang at cs.uwaterloo.ca>
Date:   Mon Aug 27 13:51:24 2012 -0400

    Correct the last call to dialog_update_label_conv
    
    If one of our buddies is/her side of the OTR session, don't
    automatically change bel on the OTR button on our side to "Finished",
    since may be other sessions for the same buddy still in ENCRYPTED.
    This was the last call to dialog_update_label_conv that still had a
    hardcoded trust label set, rather than using
    otrg_plugin_context_to_trust to get the trust label corresponding to the
    currently selected instance.
---
 ChangeLog    | 5 +++++
 gtk-dialog.c | 4 +++-
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog
index 984b25d..589a875 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -3,6 +3,11 @@
 	* otr-plugin.c: Add a timer_control callback for the last-minute
 	libotr 4 API change.
 
+	* gtk-dialog.c (otrg_gtk_dialog_finished): If one of our buddies
+	ends his/her side of the OTR session, don't automatically change
+	the label on the OTR button on our side to "Finished", since
+	there may be other sessions for the same buddy still in ENCRYPTED.
+
 2012-08-24
 
 	* otr-plugin.c: Turn off the beta dialog
diff --git a/gtk-dialog.c b/gtk-dialog.c
index 6a04af4..ebb0a71 100644
--- a/gtk-dialog.c
+++ b/gtk-dialog.c
@@ -1627,6 +1627,7 @@ static void otrg_gtk_dialog_finished(const char *accountname,
     /* See if there's a conversation window we can put this in. */
     PurpleAccount *account;
     PurpleConversation *conv;
+    ConnContext *context;
     char *buf;
 
     account = purple_accounts_find(accountname, protocol);
@@ -1645,7 +1646,8 @@ static void otrg_gtk_dialog_finished(const char *accountname,
 
     g_free(buf);
 
-    dialog_update_label_conv(conv, TRUST_FINISHED);
+    context = otrg_plugin_conv_to_selected_context(conv, 0);
+    dialog_update_label_conv(conv, otrg_plugin_context_to_trust(context));
     close_smp_window(conv);
 }
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-otr/packages/irssi-plugin-otr.git



More information about the Pkg-otr-team mailing list