[Tkabber-dev] r1025 - in trunk/tkabber: . ifacetk

tkabber-svn at jabber.ru tkabber-svn at jabber.ru
Wed Mar 7 21:46:25 MSK 2007


Author: sergei
Date: 2007-03-07 21:46:24 +0300 (Wed, 07 Mar 2007)
New Revision: 1025

Modified:
   trunk/tkabber/ChangeLog
   trunk/tkabber/ifacetk/iface.tcl
   trunk/tkabber/ifacetk/iroster.tcl
   trunk/tkabber/roster.tcl
Log:
	* roster.tcl, ifacetk/iface.tcl, ifacetk/iroster.tcl: Renamed option
	  for showing own resources in roster. Added menu item for quick
	  change in this option.


Modified: trunk/tkabber/ChangeLog
===================================================================
--- trunk/tkabber/ChangeLog	2007-03-07 15:58:27 UTC (rev 1024)
+++ trunk/tkabber/ChangeLog	2007-03-07 18:46:24 UTC (rev 1025)
@@ -17,6 +17,10 @@
 	* plugins/general/jitworkaround.tcl: Fixed bug which appeared if
 	  subscribed presence from JIT comes before the roster item.
 
+	* roster.tcl, ifacetk/iface.tcl, ifacetk/iroster.tcl: Renamed option
+	  for showing own resources in roster. Added menu item for quick
+	  change in this option.
+
 2007-03-06  Sergei Golovan  <sgolovan at nes.ru>
 
 	* chats.tcl: Fixed moving interface tabs by keyboard shortcuts

Modified: trunk/tkabber/ifacetk/iface.tcl
===================================================================
--- trunk/tkabber/ifacetk/iface.tcl	2007-03-07 15:58:27 UTC (rev 1024)
+++ trunk/tkabber/ifacetk/iface.tcl	2007-03-07 18:46:24 UTC (rev 1025)
@@ -291,10 +291,9 @@
 		   [list \
 		    [list checkbutton [::msgcat::mc "Show online users only"] \
 			 {} {} {} \
-			 -variable [namespace current]::roster::show_only_online \
-			 -command [namespace current]::roster::redraw_after_idle] \
-		    [list checkbutton [::msgcat::mc "Use aliases"] {} {} {} \
-			 -variable [namespace current]::roster::use_aliases] \
+			 -variable [namespace current]::roster::show_only_online] \
+		    [list checkbutton [::msgcat::mc "Show own resources"] {} {} {} \
+			 -variable [namespace current]::roster::options(show_own_resources)] \
 		    [list cascad [::msgcat::mc "Export roster..."] \
 			 export_roster export_roster 0 {}] \
 		    [list cascad [::msgcat::mc "Import roster..."] \

Modified: trunk/tkabber/ifacetk/iroster.tcl
===================================================================
--- trunk/tkabber/ifacetk/iroster.tcl	2007-03-07 15:58:27 UTC (rev 1024)
+++ trunk/tkabber/ifacetk/iroster.tcl	2007-03-07 18:46:24 UTC (rev 1025)
@@ -78,8 +78,8 @@
 	[::msgcat::mc "Default nested roster group delimiter."] \
 	-type string -group Roster \
 	-command [namespace current]::redraw_after_idle
-    custom::defvar options(show_self_contacts) 0 \
-	[::msgcat::mc "Show self-contacts in roster."] \
+    custom::defvar options(show_own_resources) 0 \
+	[::msgcat::mc "Show own resources in roster."] \
 	-type boolean -group Roster \
 	-command [namespace current]::redraw_after_idle
     custom::defvar options(chats_group) 0 \
@@ -110,7 +110,7 @@
 
     variable undef_group_name $::roster::undef_group_name
     variable chats_group_name $::roster::chats_group_name
-    variable self_contacts_group_name $roster::self_contacts_group_name
+    variable own_resources_group_name $roster::own_resources_group_name
 }
 
 proc roster::get_group_lists {} {
@@ -230,7 +230,7 @@
     variable show_transport_user_icons
     variable undef_group_name
     variable chats_group_name
-    variable self_contacts_group_name
+    variable own_resources_group_name
     variable collapsed
     variable show_offline
 
@@ -377,8 +377,8 @@
 	    set groupsundergroup($cgroup) {}
 	    set jidsundergroup($cgroup) {}
 	}
-	if {$options(show_self_contacts)} {
-	    set cgroup [list $self_contacts_group_name]
+	if {$options(show_own_resources)} {
+	    set cgroup [list $own_resources_group_name]
 	    set jid [::jlib::connection_bare_jid $connid]
 	    set jidsingroup($cgroup) [list $jid]
 	    set groups [linsert $groups 0 [list [join $cgroup "\u0000"] $cgroup]]

Modified: trunk/tkabber/roster.tcl
===================================================================
--- trunk/tkabber/roster.tcl	2007-03-07 15:58:27 UTC (rev 1024)
+++ trunk/tkabber/roster.tcl	2007-03-07 18:46:24 UTC (rev 1025)
@@ -3,14 +3,14 @@
 namespace eval roster {
     variable undef_group_name [::msgcat::mc "Undefined"]
     variable chats_group_name [::msgcat::mc "Active Chats"]
-    variable self_contacts_group_name [::msgcat::mc "My Resources"]
+    variable own_resources_group_name [::msgcat::mc "My Resources"]
 }
 
 proc roster::process_item {connid jid name groups subsc ask} {
     variable roster
     variable undef_group_name
     variable chats_group_name
-    variable self_contacts_group_name
+    variable own_resources_group_name
 
     debugmsg roster "ROSTER_ITEM: $connid; $jid; $name; $groups; $subsc; $ask"
 
@@ -21,7 +21,7 @@
 	    lappend roster(jids,$connid) $jid
 	}
 	set groups [lrmdups $groups]
-	foreach group [list "" $undef_group_name $chats_group_name $self_contacts_group_name] {
+	foreach group [list "" $undef_group_name $chats_group_name $own_resources_group_name] {
 	    set ind [lsearch -exact $groups $group]
 	    if {$ind >= 0} {
 		set groups [lreplace $groups $ind $ind]
@@ -430,14 +430,14 @@
     variable roster
     variable undef_group_name
     variable chats_group_name
-    variable self_contacts_group_name
+    variable own_resources_group_name
 
     set grtags {}
     foreach group $roster(group,$connid,$jid) {
 	if {![cequal $group ""] && \
 		![cequal $group $undef_group_name] && \
 		![cequal $group $chats_group_name] && \
-		![cequal $group $self_contacts_group_name]} {
+		![cequal $group $own_resources_group_name]} {
 	    lappend grtags [jlib::wrapper:createtag group -chdata $group]
 	}
     }



More information about the Tkabber-dev mailing list