[Tkabber-dev] r995 - in trunk/tkabber: . plugins/richtext

tkabber-svn at jabber.ru tkabber-svn at jabber.ru
Sun Mar 4 00:05:13 MSK 2007


Author: sergei
Date: 2007-03-04 00:05:10 +0300 (Sun, 04 Mar 2007)
New Revision: 995

Removed:
   trunk/tkabber/aniemoteicons/
Modified:
   trunk/tkabber/ChangeLog
   trunk/tkabber/plugins/richtext/emoticons.tcl
   trunk/tkabber/tkabber.tcl
Log:
	* aniemoteicons/*, tkabber.tcl, plugins/richtext/emoticons.tcl:
	  Converted aniemoticons to external plugin.


Modified: trunk/tkabber/ChangeLog
===================================================================
--- trunk/tkabber/ChangeLog	2007-03-03 19:43:58 UTC (rev 994)
+++ trunk/tkabber/ChangeLog	2007-03-03 21:05:10 UTC (rev 995)
@@ -23,6 +23,9 @@
 	  abbreviate words in chat input windows. <Shift-Space> expands
 	  abbreviations (thanks to Konstantin Khomoutov).
 
+	* aniemoteicons/*, tkabber.tcl, plugins/richtext/emoticons.tcl:
+	  Converted aniemoticons to external plugin.
+
 2007-03-02  Sergei Golovan  <sgolovan at nes.ru>
 
 	* ifacetk/iface.tcl, privacy.tcl: Redone accepting messages from

Modified: trunk/tkabber/plugins/richtext/emoticons.tcl
===================================================================
--- trunk/tkabber/plugins/richtext/emoticons.tcl	2007-03-03 19:43:58 UTC (rev 994)
+++ trunk/tkabber/plugins/richtext/emoticons.tcl	2007-03-03 21:05:10 UTC (rev 995)
@@ -141,7 +141,7 @@
 	    }
 
 	    if {! $keep} {
-		image delete $iname
+		delete_image $iname
 		unset images($iname)
 		if {[info exists txtdefaults($iname)]} {
 		    unset txtdefaults($iname)
@@ -263,7 +263,7 @@
 	}
     }
 	
-    image create photo $iname -file [file join $dir $graphic]
+    create_image $iname [file join $dir $graphic]
 
     set images($iname) 0 ;# Initial refcount is zero since it'll bumped by successive [add]s:
 
@@ -281,17 +281,13 @@
     return [namespace current]::emoticon_$mnemonic
 }
 
-if 0 {
-proc emoticons::create_image {dir graphic} {
-    set img $dir/$graphic
-    image create photo $img -file [file join $dir $graphic]
-    return $img
-}
-} else {
 proc emoticons::create_image {name file} {
     image create photo $name -file $file
     return $name
 }
+
+proc emoticons::delete_image {name} {
+    image delete $name
 }
 
 proc emoticons::show_menu {iw} {

Modified: trunk/tkabber/tkabber.tcl
===================================================================
--- trunk/tkabber/tkabber.tcl	2007-03-03 19:43:58 UTC (rev 994)
+++ trunk/tkabber/tkabber.tcl	2007-03-03 21:05:10 UTC (rev 995)
@@ -259,7 +259,6 @@
 
 load_source ifacetk bwidget_workarounds.tcl
 load_source ifacetk iface.tcl
-load_source aniemoteicons aniemoteicons.tcl
 
 plugins::load [file join plugins general]
 plugins::load [file join plugins roster]



More information about the Tkabber-dev mailing list