[Tkabber-dev] r154 - trunk/plugins/green

tkabber-svn at jabber.ru tkabber-svn at jabber.ru
Mon Oct 20 22:35:56 MSD 2008


Author: archimed
Date: 2008-10-20 22:35:56 +0400 (Mon, 20 Oct 2008)
New Revision: 154

Modified:
   trunk/plugins/green/green.tcl
Log:
Updated with new tkabber-system functions. Now works with 1566 revision of Tkabber

Modified: trunk/plugins/green/green.tcl
===================================================================
--- trunk/plugins/green/green.tcl	2008-10-20 18:31:50 UTC (rev 153)
+++ trunk/plugins/green/green.tcl	2008-10-20 18:35:56 UTC (rev 154)
@@ -47,13 +47,13 @@
 proc green::on_suspend {} {
 	variable options
 
-	set connids [jlib::connections]
+	set connids [connections]
 	if {[llength $connids] == 0} return
 
 	variable active [list]
 	foreach connid $connids {
 		if {$options(resume_sessions)} {
-			set jid [jlib::connection_bare_jid $connid]
+			set jid [connection_bare_jid $connid]
 			lappend active $jid
 		}
 		logout $connid
@@ -97,9 +97,9 @@
 }
 
 proc green::jid_connected jid {
-	set ref [node_and_server_from_jid $jid]
-	foreach connid [::jlib::connections] {
-		set cjid [::jlib::connection_bare_jid $connid]
+	set ref [::xmpp::jid::stripResource $jid]
+	foreach connid [connections] {
+		set cjid [connection_bare_jid $connid]
 		if {[string equal $ref $cjid]} {
 			return 1
 		}



More information about the Tkabber-dev mailing list