[Python-checkins] CVS: python/dist/src/Lib/lib-tk Tkinter.py,1.152,1.153

Martin v. L?wis loewis@users.sourceforge.net
Thu, 09 Aug 2001 09:57:36 -0700


Update of /cvsroot/python/python/dist/src/Lib/lib-tk
In directory usw-pr-cvs1:/tmp/cvs-serv9842

Modified Files:
	Tkinter.py 
Log Message:
Patch #403514: precompute _subst_format_str to avoid a call to 
string.join() on each invocation of _bind.


Index: Tkinter.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/lib-tk/Tkinter.py,v
retrieving revision 1.152
retrieving revision 1.153
diff -C2 -d -r1.152 -r1.153
*** Tkinter.py	2001/02/09 11:22:27	1.152
--- Tkinter.py	2001/08/09 16:57:33	1.153
***************
*** 849,854 ****
                     %
                     (add and '+' or '',
!                 funcid,
!                 " ".join(self._subst_format)))
              self.tk.call(what + (sequence, cmd))
              return funcid
--- 849,853 ----
                     %
                     (add and '+' or '',
!                 funcid, self._subst_format_str))
              self.tk.call(what + (sequence, cmd))
              return funcid
***************
*** 1013,1016 ****
--- 1012,1016 ----
               '%s', '%t', '%w', '%x', '%y',
               '%A', '%E', '%K', '%N', '%W', '%T', '%X', '%Y', '%D')
+     _subst_format_str = " ".join(_subst_format)
      def _substitute(self, *args):
          """Internal function."""