BrowserView.st
changeset 214 bb193ae3f3f9
parent 213 4b8b25b6baa1
child 216 9c60ed673ac2
equal deleted inserted replaced
213:4b8b25b6baa1 214:bb193ae3f3f9
  2030 
  2030 
  2031 renameCurrentClassTo:aString
  2031 renameCurrentClassTo:aString
  2032     "helper - do the rename"
  2032     "helper - do the rename"
  2033 
  2033 
  2034     self doClassMenu:[:currentClass |
  2034     self doClassMenu:[:currentClass |
  2035 	|oldName oldSym newSym|
  2035 	|oldName oldSym newSym cls|
       
  2036 
       
  2037 	(cls := Smalltalk classNamed:aString) notNil ifTrue:[
       
  2038 	    (self confirm:(resources string:'WARN_RENAME' with:aString with:cls category))
       
  2039 		ifFalse:[^ self]
       
  2040 	].
  2036 
  2041 
  2037 	oldName := currentClass name.
  2042 	oldName := currentClass name.
  2038 	oldSym := oldName asSymbol.
  2043 	oldSym := oldName asSymbol.
  2039 "
  2044 "
  2040 	currentClass setName:aString.
  2045 	currentClass setName:aString.
  2054 	self withWaitCursorDo:[
  2059 	self withWaitCursorDo:[
  2055 	    Transcript showCr:('searching for users of ' , oldSym); endEntry.
  2060 	    Transcript showCr:('searching for users of ' , oldSym); endEntry.
  2056 	    SystemBrowser browseReferendsOf:oldSym warnIfNone:false
  2061 	    SystemBrowser browseReferendsOf:oldSym warnIfNone:false
  2057 	]
  2062 	]
  2058     ]
  2063     ]
       
  2064 
       
  2065     "Created: 25.11.1995 / 13:02:53 / cg"
  2059 !
  2066 !
  2060 
  2067 
  2061 switchToClass:newClass
  2068 switchToClass:newClass
  2062     "switch to some other class;
  2069     "switch to some other class;
  2063      keep instance protocol as it was ..."
  2070      keep instance protocol as it was ..."
  5904 ! !
  5911 ! !
  5905 
  5912 
  5906 !BrowserView class methodsFor:'documentation'!
  5913 !BrowserView class methodsFor:'documentation'!
  5907 
  5914 
  5908 version
  5915 version
  5909 ^ '$Header: /cvs/stx/stx/libtool/BrowserView.st,v 1.50 1995-11-25 11:11:06 cg Exp $'! !
  5916 ^ '$Header: /cvs/stx/stx/libtool/BrowserView.st,v 1.51 1995-11-25 12:16:57 cg Exp $'! !
  5910 BrowserView initialize!
  5917 BrowserView initialize!