[Idle-dev] CVS: idle FileList.py,1.3,1.4

Kurt B. Kaiser kbk@users.sourceforge.net
Fri, 13 Jul 2001 21:45:34 -0700


Update of /cvsroot/idlefork/idle
In directory usw-pr-cvs1:/tmp/cvs-serv3540

Modified Files:
	FileList.py 
Log Message:
py-cvs-2000_07_13 (Rev 1.9) merge

"Delete goodname() method, which is unused. Add gotofileline(), a
convenience method which I intend to use in a
variant. Rename test() to _test()."  --GvR

This was an interesting merge. The join completely missed removing
goodname(), which was adjacent, but outside of, a small conflict.
I only caught it by comparing the 1.1.3.2/1.1.3.3 diff.  CVS ain't
infallible.


Index: FileList.py
===================================================================
RCS file: /cvsroot/idlefork/idle/FileList.py,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** FileList.py	2001/07/13 04:07:47	1.3
--- FileList.py	2001/07/14 04:45:32	1.4
***************
*** 30,42 ****
          self.vars = {} # For EditorWindow.getrawvar (shared Tcl variables)
  
- 
-     def goodname(self, filename):
-         filename = self.canonize(filename)
-         key = os.path.normcase(filename)
-         if self.dict.has_key(key):
-             edit = self.dict[key]
-             filename = edit.io.filename or filename
-         return filename
- 
      def open(self, filename, action=None):
          assert filename
--- 30,33 ----
***************
*** 63,66 ****
--- 54,62 ----
              return action(filename)
  
+     def gotofileline(self, filename, lineno=None):
+         edit = self.open(filename)
+         if edit is not None and lineno is not None:
+             edit.gotoline(lineno)
+ 
      def new(self):
          return self.EditorWindow(self)
***************
*** 132,136 ****
  
  
! def test():
      from EditorWindow import fixwordbreaks
      import sys
--- 128,132 ----
  
  
! def _test():
      from EditorWindow import fixwordbreaks
      import sys
***************
*** 148,150 ****
  
  if __name__ == '__main__':
!     test()
--- 144,146 ----
  
  if __name__ == '__main__':
!     _test()