| package |
package := Package name: 'fileNameChanger'.
package paxVersion: 1;
	basicComment: ''.

package imageStripperBytes: (ByteArray fromBase64String: 'IVNUQiAzIEYPDQAEAAAASW1hZ2VTdHJpcHBlcgAAAABSAAAADwAAAGZpbGVOYW1lQ2hhbmdlclIA
AAATAAAAZGVtb0ZpbGVDaGFuZ2VyLmV4ZZoAAABSAAAADwAAAGZpbGVOYW1lQ2hhbmdlclIAAAAg
AAAARmlsZUJyb3dzZXJSdW50aW1lU2Vzc2lvbk1hbmFnZXLn/yUAAAAAAAAAAAAAAAAAAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==').

package classNames
	add: #FileBrowser;
	add: #FileBrowserAbstract;
	add: #FileBrowserFile;
	add: #FileBrowserFolder;
	add: #FileBrowserRuntimeSessionManager;
	yourself.

package methodNames
	add: #String -> #copyReplaceAll:with:asTokens:;
	yourself.

package binaryGlobalNames: (Set new
	yourself).

package globalAliases: (Set new
	yourself).

package setPrerequisites: (IdentitySet new
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\Base\Dolphin';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Presenters\Boolean\Dolphin Boolean Presenter';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Views\Common Controls\Dolphin Common Controls';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Dialogs\Common\Dolphin Common Dialogs';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Views\Control Bars\Dolphin Control Bars';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Presenters\Image\Dolphin Image Presenter';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Models\List\Dolphin List Models';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Presenters\List\Dolphin List Presenter';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Base\Dolphin MVP Base';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Presenters\Text\Dolphin Text Presenter';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Models\Tree\Dolphin Tree Models';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Presenters\Tree\Dolphin Tree Presenter';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Type Converters\Dolphin Type Converters';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\MVP\Models\Value\Dolphin Value Models';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\ActiveX\Components\SHDocVw\Internet Explorer';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\Lagoon\Lagoon Image Stripper';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\ActiveX\Components\Picture\OLE Picture';
	add: 'D:\Dropbox\RioCollaboration\dolphin\fileNameChanger\Object Arts\Dolphin\ActiveX\Shell\Windows Shell';
	yourself).

package!

"Class Definitions"!

Object subclass: #FileBrowserAbstract
	instanceVariableNames: 'name parent children'
	classVariableNames: ''
	poolDictionaries: ''
	classInstanceVariableNames: ''!
FileBrowserAbstract subclass: #FileBrowserFile
	instanceVariableNames: 'size type timeStamp file'
	classVariableNames: ''
	poolDictionaries: ''
	classInstanceVariableNames: ''!
FileBrowserAbstract subclass: #FileBrowserFolder
	instanceVariableNames: ''
	classVariableNames: ''
	poolDictionaries: ''
	classInstanceVariableNames: ''!
Shell subclass: #FileBrowser
	instanceVariableNames: 'folders files text hex image html hexEnabled removeCr currentRootFolder showImageAs subfoldersText subfoldersCheckbox sourceReplaceText replaceText pathEditText'
	classVariableNames: 'HexEnabled HexFont RemoveCr RootFolder TextFont Warnings'
	poolDictionaries: ''
	classInstanceVariableNames: ''!
RuntimeSessionManager subclass: #FileBrowserRuntimeSessionManager
	instanceVariableNames: ''
	classVariableNames: ''
	poolDictionaries: ''
	classInstanceVariableNames: ''!

"Global Aliases"!


"Loose Methods"!

!String methodsFor!

copyReplaceAll: oldSubstring with: newSubstring asTokens: ifTokens
	"Answer a copy of the receiver in which all occurrences of
	oldSubstring have been replaced by newSubstring.
	ifTokens (valid for Strings only) specifies that the characters
	surrounding the recplacement must not be alphanumeric.
		Bruce Simth,  must be incremented by 1 and not 
	newSubstring if ifTokens is true.  See example below. "

	| aString startSearch currentIndex endIndex |
	(ifTokens and: [(self isString) not])
		ifTrue: [(self isKindOf: String) ifFalse: [
			self error: 'Token replacement only valid for Strings']].
	aString := self.
	startSearch := 1.
	[(currentIndex := aString indexOfSubCollection: oldSubstring startingAt: startSearch)
			 > 0]
		whileTrue: 
		[endIndex := currentIndex + oldSubstring size - 1.
		(ifTokens not
			or: [(currentIndex = 1
					or: [(aString at: currentIndex-1) isAlphaNumeric not])
				and: [endIndex = aString size
					or: [(aString at: endIndex+1) isAlphaNumeric not]]])
			ifTrue: [aString := aString
					copyReplaceFrom: currentIndex
					to: endIndex
					with: newSubstring.
				startSearch := currentIndex + newSubstring size]
			ifFalse: [
				ifTokens 
					ifTrue: [startSearch := currentIndex + 1]
					ifFalse: [startSearch := currentIndex + newSubstring size]]].
	^ aString! !
!String categoriesFor: #copyReplaceAll:with:asTokens:!public! !

"End of package definition"!

"Source Globals"!

"Classes"!

FileBrowserAbstract guid: (GUID fromString: '{782ED519-5423-11D3-998B-BCA753D3B065}')!
FileBrowserAbstract comment: '(C) 2005-2012 Ian Bartholomew
contact@idb.me.uk
Public Domain Freeware'!
!FileBrowserAbstract categoriesForClass!IDB Goodies! !
!FileBrowserAbstract methodsFor!

name
	"Answers the name of the receiver. This can be either a complete path (the root folder) or
	a folder name of a file name depending on the subclass used"

	^name!

parent
	"Answers the parent of the receiver or nil if it is the root"

	^parent!

path
	"Creates the path of the receiver by appending to the path of the parent (s)"

	parent ifNil: [^name].
	^File composePath: parent path subPath: name!

printOn: aStream
	"Answer the String to be used for the receiver in the tree or list"

	aStream nextPutAll: name!

setName: aString parent: aFileBrowserFolderOrNil
	"Sets the name of this objects and remembers its parent. The children (folders
	not files) will be found dynamically by the subclass"

	name := aString.
	parent := aFileBrowserFolderOrNil.
	^self! !
!FileBrowserAbstract categoriesFor: #name!accessing!public! !
!FileBrowserAbstract categoriesFor: #parent!accessing!public! !
!FileBrowserAbstract categoriesFor: #path!accessing!public! !
!FileBrowserAbstract categoriesFor: #printOn:!protocols-Object!public! !
!FileBrowserAbstract categoriesFor: #setName:parent:!initializing!public! !

!FileBrowserAbstract class methodsFor!

name: aString parent: aFileBrowserFolderOrNil
	"Answers a new instance of the receiver"

	^self new setName: aString parent: aFileBrowserFolderOrNil!

name: aString parent: aFileBrowserFolderOrNil file: aFile
	"Answers a new instance of the receiver"

	^self new setName: aString parent: aFileBrowserFolderOrNil; file: aFile; yourself! !
!FileBrowserAbstract class categoriesFor: #name:parent:!instance creation!public! !
!FileBrowserAbstract class categoriesFor: #name:parent:file:!instance creation!public! !

FileBrowserFile guid: (GUID fromString: '{782ED51A-5423-11D3-998B-BCA753D3B065}')!
FileBrowserFile comment: '(C) 2005-2012 Ian Bartholomew
contact@idb.me.uk
Public Domain Freeware'!
!FileBrowserFile categoriesForClass!IDB Goodies! !
!FileBrowserFile methodsFor!

file
	^file!

file: anObject
	file := anObject!

isChunkFile
	"Answers true if the file type is st or cls"

	^self isTypeIn: #('st' 'cls')!

isHTMLFile
	"Answers true if the file type is htm or html"

	^self isTypeIn: #('htm' 'html')!

isImageFile
	"Answers true if the file type is an image
	tif, tiff and png are (currently?) not displayed as images"

	^self isTypeIn: #('bmp' 'ico' 'jpg' 'jpeg' 'gif' 'tif' 'tiff' 'png')!

isTypeIn: aCollection
	"Answers true if the file extension is included in aCollection (case insensitive)"

	^aCollection anySatisfy: [:each | each sameAs: type]!

setName: aString parent: aFileBrowserFolderOrNil
	"initializes the extra information held about a file"

	| data |
	super setName: aString parent: aFileBrowserFolderOrNil.
	data := (File find: self path) first.
	size := data fileSize.
	type := File splitExtensionFrom: data fileName.
	timeStamp := TimeStamp fromSYSTEMTIME: data ftLastWriteTime asSYSTEMTIME.
	^self!

size
	"Answer the value of the receiver's 'size' instance variable."

	^size!

timeStamp
	"Answer the value of the receiver's 'timeStamp' instance variable."

	^timeStamp!

type
	"Answer the value of the receiver's 'type' instance variable."

	^type! !
!FileBrowserFile categoriesFor: #file!accessing!public! !
!FileBrowserFile categoriesFor: #file:!accessing!public! !
!FileBrowserFile categoriesFor: #isChunkFile!public!testing! !
!FileBrowserFile categoriesFor: #isHTMLFile!public!testing! !
!FileBrowserFile categoriesFor: #isImageFile!public!testing! !
!FileBrowserFile categoriesFor: #isTypeIn:!public!testing! !
!FileBrowserFile categoriesFor: #setName:parent:!initializing!public! !
!FileBrowserFile categoriesFor: #size!accessing!public! !
!FileBrowserFile categoriesFor: #timeStamp!accessing!public! !
!FileBrowserFile categoriesFor: #type!accessing!public! !

FileBrowserFolder guid: (GUID fromString: '{782ED51B-5423-11D3-998B-BCA753D3B065}')!
FileBrowserFolder comment: '(C) 2005-2012 Ian Bartholomew
contact@idb.me.uk
Public Domain Freeware'!
!FileBrowserFolder categoriesForClass!IDB Goodies! !
!FileBrowserFolder methodsFor!

children
	"Answers the children (folders) of the receiver"

	children ifNil: [children := self getChildren].
	^children!

files
	"Answers the children (files) of the receiver sorted in alpha order"

	| files |
	files := (File find: self searchPath) select: [:each | (each dwFileAttributes bitAnd: 16) = 0].
	files := files collect: [:each | FileBrowserFile name: each cFileName parent: self file: each].
	^files asSortedCollection: [:a :b | a name <= b name]!

getAllSubfiles
	"answer all files in all subdirectories of this folder"
	|fileCollection|
	fileCollection := OrderedCollection new.
	(self children size == 0) & (self files size = 0 ) ifTrue: [^OrderedCollection new]. 
	self children size > 0 ifTrue: [  self getChildren do: [ :each| fileCollection addAll: each getAllSubfiles ]. fileCollection addAll: self files. ^fileCollection]
				ifFalse: [^ (self files) ]!

getChildren
	"Answers the cildren (folders) of the receiver sorted in alpha order"

	| folders |
	folders := (File find: self searchPath) select: [:each | (each dwFileAttributes bitAnd: 16) ~= 0].
	folders := folders reject: [:each | each cFileName first = $.].
	folders := folders collect: [:each | FileBrowserFolder name: each fileName parent: self].
	^folders asSortedCollection: [:a :b | a name <= b name]!

searchPath
	"Answers the search path, the path appended with *.*, for the receiver"

	^File
		composePath: self path
		stem: '*'
		extension: '*'! !
!FileBrowserFolder categoriesFor: #children!accessing!public! !
!FileBrowserFolder categoriesFor: #files!accessing!public! !
!FileBrowserFolder categoriesFor: #getAllSubfiles!public! !
!FileBrowserFolder categoriesFor: #getChildren!accessing!public! !
!FileBrowserFolder categoriesFor: #searchPath!accessing!public! !

FileBrowser guid: (GUID fromString: '{782ED51C-5423-11D3-998B-BCA753D3B065}')!
FileBrowser comment: '(C) 2005-2012 Ian Bartholomew
contact@idb.me.uk
Public Domain Freeware'!
!FileBrowser categoriesForClass!IDB Goodies! !
!FileBrowser methodsFor!

askAboutHex: anInteger
	"Give the chance to turn off hex if the option is on and the file size greater than 50000"

	anInteger < 50000 ifTrue: [^true].
	(MessageBox
		confirm:
			'The hex option is on and the selected file is ' , (anInteger // 1024) printString
				,
					' KB in size.
This may take a little time to render.
Do you want to turn the hex option off before continuing?') ifTrue: [hexEnabled := false].
	^hexEnabled!

canFileIn
	"Answers true if a file is selected and it's extension is st or cls"

	^files hasSelection and: [files selection isChunkFile]!

canPrint
	^[super canPrint] on: MessageNotUnderstood do: [:e | false]!

clearTabs
	"Empty all the tab pages"

	text value: String new.
	hex value: String new.
	image value: nil.
	html value: 'about:blank'!

createComponents
	"Private - Create the presenters contained by the receiver"

	super createComponents.
	folders := self add: TreePresenter new name: 'folders'.
	files := self add: ListPresenter new name: 'files'.
	text := self add: TextPresenter new name: 'text'.
	hex := self add: TextPresenter new name: 'hex'.
	image := self add: ImagePresenter new name: 'image'.
	html := self add: URLPresenter new name: 'html'.
	subfoldersText := self add: TextPresenter new name: 'subfoldersText'.
	subfoldersText value: 'Include Subdirectories'.
	subfoldersCheckbox := self add: BooleanPresenter new name: 'subfoldersCheck'.
	sourceReplaceText := self add: TextPresenter new name: 'replaceStringSourceText'.
	replaceText := self add: TextPresenter new name: 'replaceWithText'.
	pathEditText := self add: TextPresenter new name: 'pathedit'.!

createSchematicWiring
	"Private - Create the trigger wiring for the receiver"

	super createSchematicWiring.
	self 
		when: #closeRequested:
		send: #onCloseRequested:
		to: self.
	folders 
		when: #selectionChanged
		send: #onFolderSelectionChanged
		to: self.
	folders 
		when: #selectionChanging:
		send: #onSelectionChanging:
		to: self.
	files 
		when: #selectionChanged
		send: #onFileSelectionChanged
		to: self.
	files 
		when: #selectionChanging:
		send: #onSelectionChanging:
		to: self.
	text 
		when: #keyEvent:
		send: #onKeyEvent:
		to: self.
	subfoldersCheckbox 
		when: #valueChanged
		send: #onFolderSelectionChanged
		to: self.
	SessionManager current 
		when: #sessionStarted
		send: #onSessionStarted
		to: self!

enableHex
	"Enable the creation of the Hex text. This can be quite slow for larger files"

	hexEnabled := hexEnabled not.
	self updateFilesKeepingSelection!

fileDelete
	"Delete the selected file. If warnings are enable we have to confirm this operation"

	files hasSelection ifFalse: [^self].
	self class warnings
		ifTrue:
			[(MessageBox
				confirm:
					files selection path
						,
							' will be deleted.
OK to continue?') ifFalse: [^self]].
	File delete: files selection path.
	self onFolderSelectionChanged!

fileIn
	"Only enabled for chunk (st and cls) files. Loads the file into the image"

	self class sourceManager fileIn: files selection path!

fileNew
	"Just clear any selected file and make sure the text views are cleared 
	to allow a new file to be created. Check for a modified text view first"

	
	files selectionOrNil: nil.
	self clearTabs!

fileOpen
	"Change the root folder displayed in the tree - nothing to do with files really.
	Check for modified files first as if we allow the normal check on a folder changing
	the tree seems to get confused. It's best to do it before the folder dialog anyway.
	Make the root folder sticky across image saves"

	| root rootName |
	
	(rootName := BrowseFolderDialog showModal) ifNil: [^self].	"Can't just add this as the path may already end in \ e.g. c:\"
	rootName last = $\ ifFalse: [rootName := rootName , '\'].
	folders model roots: (Array with: (root := FileBrowserFolder name: rootName parent: nil)).
	folders selection: root.
	currentRootFolder := rootName!

fileSave
	"Save any changes to the file"

	files hasSelection ifFalse: [^self fileSaveAs].
	self saveFile: files selection path.
	self updateFilesKeepingSelection!

fileSaveAs
	"Save any changes to the text view in a new file"

	| pathname |
	pathname := folders hasSelection
		ifTrue: [FileSaveDialog showModalOn: folders selection searchPath]
		ifFalse: [FileSaveDialog showModal].
	pathname ifNil: [^self].
	self saveFile: pathname.
	self updateFilesKeepingSelection!

idbAbout
	"Display the about view"

	self
		idbAbout:
			'<n>File Browser<n>for<n>Dolphin Smalltalk 6.x<n><n>Version 6b<n>© 2005 Ian Bartholomew<n>http://www.idb.me.uk'
				expandMacros!

onCloseRequested: aValueHolder
	"The shell is about to be closed. Check for any changes before allowing this"

	SessionManager current removeEventsTriggeredFor: self.
	^self
	!

onFileSelectionChanged
	"The file selection has changed so update the text views and the caption"

	| newCaption rawText |
	newCaption := files hasSelection
		ifTrue:
			[| fileStream |
			fileStream := FileStream read: files selection path.
			rawText := [fileStream contents] ensure: [fileStream close].
			text value: rawText.
			self setImage: files selection.
			self setHTML: files selection.
			files selection path]
		ifFalse:
			[self clearTabs.
			String new].
	(hexEnabled and: [rawText notNil and: [rawText notEmpty]])
		ifTrue:
			[(self askAboutHex: rawText size)
				ifTrue: [Cursor wait showWhile: [hex value: rawText asHexText]]
				ifFalse: [hex value: String new]]
		ifFalse: [hex value: String new].
	self caption: 'File Browser - ' , newCaption!

onFolderSelectionChanged
	"The folder selection has changed so update the file list. We have to make sure that
	the text views are cleared as well as the #onFileSelectionChanged method is not 
	automatically called"
	
	
	files
		list: (folders hasSelection ifTrue: [
			subfoldersCheckbox value ifTrue: [folders selection getAllSubfiles]
				ifFalse: [folders selection files]]
 ifFalse: [OrderedCollection new]).
	files view layout.
	self clearTabs!

onSelectionChanging: aValueHolder
	"A selection, either the folder or the file, is changing so check to see if there have been any 
	modifications to the text view before allowing the change"

	
	^self!

onSessionStarted
	"A new session has been started with the FileBrowser open so make sure it is consistent"

	currentRootFolder ifNil: [currentRootFolder := self class rootFolder].
	(File exists: currentRootFolder) ifFalse: [currentRootFolder := self class defaultRootFolder].
	folders
		model:
			(VirtualTreeModel withRoots: (Array with: (FileBrowserFolder name: currentRootFolder parent: nil)))!

onViewOpened
	"The view has opened. Get the initial values from the class variables. These can be
	set in the DolphinOptions folder"

	super onViewOpened.
	hexEnabled := self class hexEnabled.
	removeCr := self class removeCr.
	text view font: self class textFont.
	hex view font: self class hexFont.
	folders
		model:
			(VirtualTreeModel
				withRoots: (Array with: (FileBrowserFolder name: 'c:\' parent: nil))).
	showImageAs := #scaleToFit!

printableView
	^(self view viewNamed: 'cards') currentCard view!

promptForChanges
	"If warnings are enabled and if the text view has been modified ask for confirmation.
	Answer false if we can continue, possibly losing changed text or true if we want to allow
	the text to be saved. We have to reset the isModified flag to prevent multiple prompts and
	we might as well clear the text pane to prevent confusion"

	| answer |
	self class warnings ifFalse: [^false].
	text isModified ifFalse: [^false].
	(answer := MessageBox
		confirm:
			'There are unsaved changes.
Do you want to retain them?')
		ifFalse:
			[text
				text: String new;
				isModified: false].
	^answer!

queryCommand: aCommandQuery
	"Enters details about a potential command for the receiver into aCommandQuery"

	(#(#fileSave #fileDelete) includes: aCommandQuery command)
		ifTrue:
			[aCommandQuery isEnabled: files hasSelection.
			^true].
	#enableHex == aCommandQuery command
		ifTrue:
			[aCommandQuery
				isEnabled: true;
				isChecked: hexEnabled.
			^true].
	#removeCr == aCommandQuery command
		ifTrue:
			[aCommandQuery
				isEnabled: true;
				isChecked: removeCr.
			^true].
	#fileIn == aCommandQuery command
		ifTrue:
			[aCommandQuery isEnabled: self canFileIn.
			^true].
	(#(#print #printPreview) identityIncludes: aCommandQuery command)
		ifTrue:
			[aCommandQuery isEnabled: self canPrint.
			^true].
	^super queryCommand: aCommandQuery!

removeCr
	"Toggle whether we remove Crs on saving"

	removeCr := removeCr not!

replace
	| sourceString replaceString fileTargets |
	sourceReplaceText value = '' ifTrue: [^self].
	sourceString := sourceReplaceText value.
	replaceString := replaceText value.
	fileTargets := files model.
	fileTargets do: 
			[:each | 
			| oldName newName |
			oldName := each name.
			oldName := oldName leftString: oldName size - (each type size + 1).
			(oldName findString: sourceString) ~= 0 
				ifTrue: 
					[newName := oldName 
								copyReplaceAll: sourceString
								with: replaceString
								asTokens: false.
					newName := newName , '.' , each type.
					File rename: each file directory , each name to: each file directory , newName]].
	self onFolderSelectionChanged.!

saveFile: pathname
	"Save the file after stripping crs if required"

	| fileStream rawText |
	rawText := text view plainText.
	removeCr ifTrue: [rawText := rawText copyWithout: Character cr].
	fileStream := FileStream write: pathname.
	[fileStream nextPutAll: rawText] ensure: [fileStream close].
	text isModified: false!

setHTML: aFileBrowserFile
	"If the selected file is a html file then diplay it on the html tab"

	aFileBrowserFile isHTMLFile ifFalse: [^html value: 'about:blank'].
	html value: aFileBrowserFile path!

setImage: aFileBrowserFile
	"If the selected file is an image file then diplay it on the image tab"

	aFileBrowserFile isImageFile ifFalse: [^image value: nil].
	image value: (OLEPicture fromFile: aFileBrowserFile path).
	(image view)
		viewMode: showImageAs;
		layout!

showImageAs: aSymbol
	showImageAs := aSymbol.
	files hasSelection ifTrue: [self setImage: files selection]!

updateFilesKeepingSelection
	"Update the files list but keep the current selection. We can't just use the same selection
	as the actual items in the list will have been recreated so the actual old selection will have
	gone. We have to reselect the item representing the same file"

	| selection |
	files hasSelection ifTrue: [selection := files selection name].
	self onFolderSelectionChanged.
	selection
		ifNotNil:
			[files selectionOrNil: (files list detect: [:each | each name = selection] ifNone: [nil])]! !
!FileBrowser categoriesFor: #askAboutHex:!helpers!public! !
!FileBrowser categoriesFor: #canFileIn!commands!public!testing! !
!FileBrowser categoriesFor: #canPrint!printing!public!testing! !
!FileBrowser categoriesFor: #clearTabs!helpers!public! !
!FileBrowser categoriesFor: #createComponents!initializing!public! !
!FileBrowser categoriesFor: #createSchematicWiring!initializing!public! !
!FileBrowser categoriesFor: #enableHex!commands!public! !
!FileBrowser categoriesFor: #fileDelete!commands!public! !
!FileBrowser categoriesFor: #fileIn!commands!public! !
!FileBrowser categoriesFor: #fileNew!commands!public! !
!FileBrowser categoriesFor: #fileOpen!commands!public! !
!FileBrowser categoriesFor: #fileSave!commands!public! !
!FileBrowser categoriesFor: #fileSaveAs!commands!public! !
!FileBrowser categoriesFor: #idbAbout!commands!public! !
!FileBrowser categoriesFor: #onCloseRequested:!event handling!public! !
!FileBrowser categoriesFor: #onFileSelectionChanged!event handling!public! !
!FileBrowser categoriesFor: #onFolderSelectionChanged!event handling!public! !
!FileBrowser categoriesFor: #onSelectionChanging:!event handling!public! !
!FileBrowser categoriesFor: #onSessionStarted!event handling!public! !
!FileBrowser categoriesFor: #onViewOpened!event handling!public! !
!FileBrowser categoriesFor: #printableView!accessing!printing!public! !
!FileBrowser categoriesFor: #promptForChanges!helpers!public! !
!FileBrowser categoriesFor: #queryCommand:!commands!public! !
!FileBrowser categoriesFor: #removeCr!commands!public! !
!FileBrowser categoriesFor: #replace!public! !
!FileBrowser categoriesFor: #saveFile:!helpers!public! !
!FileBrowser categoriesFor: #setHTML:!helpers!public! !
!FileBrowser categoriesFor: #setImage:!helpers!public! !
!FileBrowser categoriesFor: #showImageAs:!commands!public! !
!FileBrowser categoriesFor: #updateFilesKeepingSelection!helpers!public! !

!FileBrowser class methodsFor!

defaultHexEnabled
	^false!

defaultHexFont
	^Font name: 'Courier New' pointSize: 10!

defaultRemoveCr
	^false!

defaultRootFolder
	^SessionManager current imageBase!

defaultTextFont
	^Font name: 'Times New Roman' pointSize: 12!

defaultWarnings
	^true!

displayOn: aStream
	aStream nextPutAll: 'File Browser'!

hexEnabled
	"Answer whether the hex display is enabled"

	^HexEnabled ifNil: [self defaultHexEnabled]!

hexEnabled: aBoolean
	"Set whether the hex display is enabled"

	HexEnabled := aBoolean!

hexFont
	"Answer the font used for the hex view"

	^HexFont ifNil: [self defaultHexFont]!

hexFont: aFont
	"Set the font used for the hex view"

	HexFont := aFont!

removeCr
	"Answer whether we reove Crs before saving"

	^RemoveCr ifNil: [self defaultRemoveCr]!

removeCr: aBoolean
	"Set whether we remove Crs when saving"

	RemoveCr := aBoolean!

resource_Default_view
	"Answer the literal data from which the 'Default view' resource can be reconstituted.
	DO NOT EDIT OR RECATEGORIZE THIS METHOD.

	If you wish to modify this resource evaluate:
	ViewComposer openOn: (ResourceIdentifier class: self selector: #resource_Default_view)
	"

	^#(#'!!STL' 3 788558 10 ##(Smalltalk.STBViewProxy)  8 ##(Smalltalk.ShellView)  98 27 0 0 98 2 27131905 131073 416 0 721158 ##(Smalltalk.SystemColor)  31 0 551 0 0 0 416 788230 ##(Smalltalk.BorderLayout)  1 1 410 8 ##(Smalltalk.Toolbar)  98 25 0 416 98 2 8 1140853548 131137 544 0 524550 ##(Smalltalk.ColorRef)  8 4278190080 0 519 0 263174 ##(Smalltalk.Font)  0 16 459014 ##(Smalltalk.LOGFONT)  8 #[243 255 255 255 0 0 0 0 0 0 0 0 0 0 0 0 144 1 0 0 0 0 0 0 3 2 1 34 65 114 105 97 108 0 100 197 66 49 15 1 0 0 196 53 15 1 5 0 144 39 0 0 0 0 199 0 253 85 63 1] 328198 ##(Smalltalk.Point)  193 193 0 544 626 656 8 4294902955 234 256 98 0 234 256 832 202 208 832 234 240 832 0 1 0 754 33 31 754 45 45 0 514 1 1 410 8 ##(Smalltalk.ContainerView)  98 15 0 544 98 2 8 1140850688 131073 944 0 0 0 7 0 0 0 944 514 1 1 410 960 98 15 0 944 98 2 8 1140850688 131073 1040 0 0 0 7 0 0 0 1040 1180166 ##(Smalltalk.ProportionalLayout)  234 240 98 4 410 8 ##(Smalltalk.TextEdit)  98 16 0 1040 98 2 8 1140916352 1025 1168 0 626 8 4278190080 0 7 0 0 0 1168 0 8 4294902713 852486 ##(Smalltalk.NullConverter)  0 0 1 983302 ##(Smalltalk.MessageSequence)  202 208 98 4 721670 ##(Smalltalk.MessageSend)  8 #createAt:extent: 98 2 754 71 1 754 1749 37 1168 1394 8 #selectionRange: 98 1 525062 ##(Smalltalk.Interval)  3 1 3 1168 1394 8 #isTextModified: 98 1 32 1168 1394 8 #setMarginWidths: 98 1 98 2 7 7 1168 983302 ##(Smalltalk.WINDOWPLACEMENT)  8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 35 0 0 0 0 0 0 0 141 3 0 0 18 0 0 0] 98 0 754 193 193 0 27 3 410 8 ##(Smalltalk.StaticText)  98 16 0 1040 98 2 8 1140850944 1 1760 0 0 0 7 0 0 0 1760 0 8 4294902715 1298 0 0 0 1330 202 208 98 2 1394 1424 98 2 754 1 1 754 71 37 1760 1394 8 #text: 98 1 8 'Path:' 1760 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 0 0 0 0 35 0 0 0 18 0 0 0] 98 0 1744 0 27 1 32 234 256 98 2 1168 8 'pathedit' 0 1330 202 208 98 1 1394 1424 98 2 754 1 1 754 1819 37 1040 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 0 0 0 0 141 3 0 0 18 0 0 0] 98 2 1760 1168 1744 0 27 0 0 0 410 960 98 15 0 944 98 2 8 1140850688 131073 2304 0 0 0 7 0 0 0 2304 656198 1 ##(Smalltalk.FlowLayout)  1 1 1 234 256 832 0 1330 202 208 98 1 1394 1424 98 2 754 1 37 754 1819 59 2304 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 18 0 0 0 141 3 0 0 47 0 0 0] 98 2 410 960 98 15 0 2304 98 2 8 1140850688 131073 2576 0 0 0 7 0 0 0 2576 0 234 256 98 2 410 8 ##(Smalltalk.CheckBox)  98 16 0 2576 98 2 8 1409363715 1 2672 721990 2 ##(Smalltalk.ValueHolder)  0 0 1114118 ##(Smalltalk.NeverSearchPolicy)  32 0 0 7 0 0 0 2672 0 8 4294902563 1298 0 0 0 1330 202 208 98 1 1394 1424 98 2 754 25 17 754 371 29 2672 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 12 0 0 0 8 0 0 0 197 0 0 0 22 0 0 0] 98 0 1744 0 27 8 'subfoldersCheck' 0 1330 202 208 98 1 1394 1424 98 2 754 1 1 754 61 51 2576 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 0 0 0 0 30 0 0 0 25 0 0 0] 98 1 2672 1744 0 27 410 960 98 15 0 2304 98 2 8 1140850688 131073 3184 0 0 0 7 0 0 0 3184 514 1 1 410 960 98 15 0 3184 98 2 8 1140850688 131073 3264 0 0 0 7 0 0 0 3264 0 234 256 832 0 1330 202 208 98 1 1394 1424 98 2 754 1 1 754 261 13 3264 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 0 0 0 0 130 0 0 0 6 0 0 0] 98 0 1744 0 27 0 0 0 410 1776 98 16 0 3184 98 2 8 1140850945 1 3504 0 0 0 7 0 0 0 3504 786694 ##(Smalltalk.IndexedColor)  33554433 8 4294902715 1298 0 0 0 1330 202 208 98 2 1394 1424 98 2 754 1 13 754 261 47 3504 1394 2000 98 1 8 'Include Subfolders' 3504 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 6 0 0 0 130 0 0 0 29 0 0 0] 98 0 1744 0 27 234 256 98 2 3504 8 'subfoldersText' 0 1330 202 208 98 1 1394 1424 98 2 754 61 1 754 261 59 3184 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 30 0 0 0 0 0 0 0 160 0 0 0 29 0 0 0] 98 2 3264 3504 1744 0 27 1744 0 27 234 256 832 0 1330 202 208 98 1 1394 1424 98 2 754 1 1 754 1819 95 944 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 0 0 0 0 141 3 0 0 47 0 0 0] 98 2 1040 2304 1744 0 27 0 0 0 0 1330 202 208 98 2 1394 1424 98 2 754 1 1 754 1819 95 544 1394 8 #updateSize 832 544 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 0 0 0 0 141 3 0 0 47 0 0 0] 98 1 944 1744 0 27 410 8 ##(Smalltalk.StatusBar)  98 18 0 416 98 2 8 1140850956 1 4416 0 482 31 0 7 0 674 0 16 706 8 #[243 255 255 255 0 0 0 0 0 0 0 0 0 0 0 0 144 1 0 0 0 0 0 0 3 2 1 34 65 114 105 97 108 0 100 197 66 49 15 1 0 0 196 53 15 1 5 0 144 39 0 0 0 0 199 0 253 85 63 1] 754 193 193 0 4416 0 8 4294902379 234 256 832 202 208 98 1 1115142 ##(Smalltalk.StatusBarNullItem)  513 1 4416 0 4656 0 1330 202 208 98 1 1394 1424 98 2 754 1 1131 754 1819 45 4416 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 53 2 0 0 141 3 0 0 75 2 0 0] 98 0 1744 0 27 0 0 410 960 98 15 0 416 98 2 8 1140850688 131073 4832 0 482 31 0 7 0 0 0 4832 514 1 1 410 960 98 15 0 4832 98 2 8 1140850688 131073 4928 0 482 31 0 7 0 0 0 4928 514 1 1 0 0 410 960 98 15 0 4928 98 2 8 1140850688 131073 5024 0 626 656 0 7 0 0 0 5024 514 1 1 0 0 0 0 410 8 ##(Smalltalk.ListView)  98 30 0 5024 98 2 8 1140920397 1025 5120 590662 2 ##(Smalltalk.ListModel)  202 208 832 0 1310726 ##(Smalltalk.IdentitySearchPolicy)  626 656 0 7 265030 4 ##(Smalltalk.Menu)  0 16 98 5 984134 2 ##(Smalltalk.CommandMenuItem)  1 1180998 4 ##(Smalltalk.CommandDescription)  8 #fileSave 8 '&Save file' 1 1 0 0 0 983366 1 ##(Smalltalk.DividerMenuItem)  4097 5346 1 5378 8 #fileIn 8 '&File in' 1 1 0 0 0 5442 4097 5346 1 5378 8 #fileDelete 8 '&Delete file' 1 1 0 0 0 8 '' 0 1 0 0 0 0 0 0 0 5120 0 8 4294902415 8 ##(Smalltalk.BasicListAbstract)  0 1049670 1 ##(Smalltalk.IconImageManager)  0 0 0 0 0 0 202 208 98 4 920646 5 ##(Smalltalk.ListViewColumn)  8 'Name' 983 8 #left 5648 8 ##(Smalltalk.SortedCollection)  459270 ##(Smalltalk.Message)  8 #name 98 0 0 5120 0 3 0 0 5730 8 'Type' 101 8 #right 5648 5792 5810 8 #type 5856 0 5120 0 1 0 0 5730 8 'Size' 161 5904 5648 5792 5810 8 #size 5856 0 5120 0 1 0 0 5730 8 'Date' 161 5904 5648 5792 5810 8 #timeStamp 5856 0 5120 0 1 0 0 8 #report 832 0 131169 0 0 1330 202 208 98 3 1394 1424 98 2 754 1 1 754 1403 597 5120 1394 8 #contextMenu: 98 1 5312 5120 1394 2000 98 1 8 'Name' 5120 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 0 0 0 0 189 2 0 0 42 1 0 0] 98 0 1744 0 27 234 256 98 2 5120 8 'files' 0 1330 202 208 98 1 1394 1424 98 2 754 409 1 754 1403 597 5024 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 204 0 0 0 0 0 0 0 137 3 0 0 42 1 0 0] 98 1 5120 1744 0 27 410 960 98 15 0 4928 98 2 8 1140850688 131073 6560 0 626 656 0 7 0 0 0 6560 514 1 1 0 0 0 0 410 8 ##(Smalltalk.TreeView)  98 27 0 6560 98 2 8 1140916775 1025 6656 590918 3 ##(Smalltalk.TreeModel)  0 5264 525062 ##(Smalltalk.TreeNode)  0 0 0 234 256 832 626 656 0 7 0 0 0 6656 0 8 4294902465 5648 8 ##(Smalltalk.IconicListAbstract)  5680 0 0 0 0 0 234 240 832 17 8 #noIcons 1 0 1330 202 208 98 1 1394 1424 98 2 754 1 1 754 401 597 6656 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 0 0 0 0 200 0 0 0 42 1 0 0] 98 0 1744 0 27 234 256 98 2 6656 8 'folders' 0 1330 202 208 98 1 1394 1424 98 2 754 9 1 754 401 597 6560 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 4 0 0 0 0 0 0 0 204 0 0 0 42 1 0 0] 98 1 6656 1744 0 27 410 8 ##(Smalltalk.Splitter)  98 12 0 4928 98 2 8 1140850688 1 7264 0 626 656 0 7 0 0 0 7264 1330 202 208 98 1 1394 1424 98 2 754 409 1 754 1 597 7264 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 204 0 0 0 0 0 0 0 204 0 0 0 42 1 0 0] 98 0 1744 0 27 234 256 832 590342 ##(Smalltalk.Rectangle)  754 9 1 754 9 5 1330 202 208 98 1 1394 1424 98 2 754 1 1 754 1819 601 4928 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 0 0 0 0 141 3 0 0 44 1 0 0] 98 3 6560 7264 5024 1744 0 27 0 0 0 410 960 98 15 0 4832 98 2 8 1140850688 131073 7760 0 3570 33554471 0 7 0 0 0 7760 0 234 256 98 10 410 1776 98 16 0 7760 98 2 8 1140850944 1 7872 0 0 0 7 0 0 0 7872 0 8 4294902715 1298 0 0 0 1330 202 208 98 2 1394 1424 98 2 754 171 81 754 71 41 7872 1394 2000 98 1 8 'With:' 7872 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 85 0 0 0 40 0 0 0 120 0 0 0 60 0 0 0] 98 0 1744 0 27 8 'withStringLabel' 410 1184 98 16 0 7760 98 2 8 1140916352 1025 8192 0 626 8 4278190080 0 7 0 0 0 8192 0 8 4294902713 1298 0 0 1 1330 202 208 98 4 1394 1424 98 2 754 271 81 754 401 41 8192 1394 1504 98 1 1538 3 1 3 8192 1394 1584 98 1 32 8192 1394 1632 98 1 98 2 7 7 8192 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 135 0 0 0 40 0 0 0 79 1 0 0 60 0 0 0] 98 0 1744 0 27 8 'replaceWithText' 410 8 ##(Smalltalk.PushButton)  98 20 0 7760 98 2 8 1140924416 1 8624 0 0 0 7 0 0 0 8624 0 8 4294902563 5378 8 #replace 8 '&OK' 1 1 0 0 16 0 0 0 1330 202 208 98 3 1394 1424 98 2 754 271 131 754 141 51 8624 1394 8 #isEnabled: 98 1 32 8624 1394 2000 98 1 8 '&OK' 8624 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 135 0 0 0 65 0 0 0 205 0 0 0 90 0 0 0] 98 0 1744 0 29 8 'replaceStringButton' 410 1184 98 16 0 7760 98 2 8 1140916352 1025 9040 0 626 8272 0 7 0 0 0 9040 0 8 4294902713 1298 0 0 1 1330 202 208 98 4 1394 1424 98 2 754 271 31 754 401 41 9040 1394 1504 98 1 1538 3 1 3 9040 1394 1584 98 1 32 9040 1394 1632 98 1 98 2 7 7 9040 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 135 0 0 0 15 0 0 0 79 1 0 0 35 0 0 0] 98 0 1744 0 27 8 'replaceStringSourceText' 410 1776 98 16 0 7760 98 2 8 1140850944 1 9456 0 0 0 7 0 0 0 9456 0 8 4294902715 1298 0 0 0 1330 202 208 98 2 1394 1424 98 2 754 141 31 754 101 41 9456 1394 2000 98 1 8 'Replace:' 9456 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 70 0 0 0 15 0 0 0 120 0 0 0 35 0 0 0] 98 0 1744 0 27 8 'replaceStringLabel' 0 1330 202 208 98 1 1394 1424 98 2 754 1 601 754 1819 437 7760 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 44 1 0 0 141 3 0 0 6 2 0 0] 98 5 9040 8192 9456 8624 7872 1744 0 27 234 256 832 0 1330 202 208 98 1 1394 1424 98 2 754 1 95 754 1819 1037 4832 1682 8 #[44 0 0 0 0 0 0 0 1 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 0 0 0 0 47 0 0 0 141 3 0 0 53 2 0 0] 98 2 4928 7760 1744 0 27 234 256 98 2 544 8 'toolbar' 0 461638 4 ##(Smalltalk.MenuBar)  0 16 98 4 5298 0 16 98 13 5346 1 5378 8 #fileNew 8 '&New file' 1 1 0 0 0 5346 1 5378 8 #fileOpen 8 'Root folder' 1 1 0 0 0 5346 1 5378 5408 8 '&Save file' 1 1 0 0 0 5346 1 5378 8 #fileSaveAs 8 'Save file &as' 1 1 0 0 0 5442 4097 5346 1 5378 8 #enableHex 8 'Enable Hex' 1 1 0 0 0 5346 1 5378 8 #removeCr 8 'Remove Cr' 1 1 0 0 0 5442 4097 5346 1 5378 8 #pageSetup 8 'Page setup...' 1 1 0 0 0 5346 1 5378 8 #printPreview 8 'Print preview...' 1 1 0 0 0 5346 1 5378 8 #print 8 'Print...' 1 1 0 0 0 5442 4097 5346 1 5378 8 #exit 8 'Close' 16615 1 0 0 0 8 '&File' 0 1 0 0 18265 0 0 5298 0 16 98 11 5346 1 5378 8 #undo 8 '&Undo' 9397 1 0 0 0 5442 4097 5346 1 5378 8 #cutSelection 8 'Cu&t' 9393 1 0 0 0 5346 1 5378 8 #copySelection 8 '&Copy' 9351 1 0 0 0 5346 1 5378 8 #pasteClipboard 8 '&Paste' 9389 1 0 0 0 5346 1 5378 8 #clearSelection 8 '&Delete' 1 1 0 0 0 5346 1 5378 8 #selectAll 8 'Select &All' 9347 1 0 0 0 5442 4097 5346 1 5378 8 #find 8 '&Find...' 9357 1 0 0 0 5346 1 5378 8 #findNext 8 'Find &Next' 1253 1 0 0 0 5346 1 5378 8 #findReplace 8 '&Replace...' 9361 1 0 0 0 8 '&Edit' 0 1 0 0 18285 0 0 5298 0 16 98 0 8 '&Tools' 8 #toolsMenu 1 0 0 18287 0 0 5298 0 16 98 2 5346 1 5378 8 #idbHelp 8 '&Help' 1 1 0 0 0 5346 1 5378 8 #idbAbout 8 '&About' 1 1 0 0 0 8 '&Help' 0 134217729 0 0 18293 0 0 8 '' 0 1 0 0 0 0 0 0 0 0 9619 0 0 0 0 1 0 0 1330 202 208 98 3 1394 1424 98 2 754 2731 21 754 1851 1291 416 1394 2000 98 1 8 'File Browser' 416 1394 8 #updateMenuBar 832 416 1682 8 #[44 0 0 0 0 0 0 0 0 0 0 0 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 255 85 5 0 0 10 0 0 0 242 8 0 0 143 2 0 0] 98 3 544 4832 4416 1744 0 27 )!

rootFolder
	"Answer the name of the root folder in the tree"

	^RootFolder ifNil: [self defaultRootFolder]!

rootFolder: aString
	"Set the name of the root folder in the tree"

	RootFolder := aString!

textFont
	"Answer the font used for the text view"

	^TextFont ifNil: [self defaultTextFont]!

textFont: aFont
	"Set the font used for the text view"

	TextFont := aFont!

warnings
	"Answer whether warnings are enabled"

	^Warnings ifNil: [self defaultWarnings]!

warnings: aBoolean
	"Set whether warnings are enabled"

	Warnings := aBoolean! !
!FileBrowser class categoriesFor: #defaultHexEnabled!constants!public! !
!FileBrowser class categoriesFor: #defaultHexFont!constants!public! !
!FileBrowser class categoriesFor: #defaultRemoveCr!constants!public! !
!FileBrowser class categoriesFor: #defaultRootFolder!constants!public! !
!FileBrowser class categoriesFor: #defaultTextFont!constants!public! !
!FileBrowser class categoriesFor: #defaultWarnings!constants!public! !
!FileBrowser class categoriesFor: #displayOn:!operations!public! !
!FileBrowser class categoriesFor: #hexEnabled!accessing!public! !
!FileBrowser class categoriesFor: #hexEnabled:!accessing!public! !
!FileBrowser class categoriesFor: #hexFont!accessing!public! !
!FileBrowser class categoriesFor: #hexFont:!accessing!public! !
!FileBrowser class categoriesFor: #removeCr!accessing!public! !
!FileBrowser class categoriesFor: #removeCr:!accessing!public! !
!FileBrowser class categoriesFor: #resource_Default_view!public!resources-views! !
!FileBrowser class categoriesFor: #rootFolder!accessing!public! !
!FileBrowser class categoriesFor: #rootFolder:!accessing!public! !
!FileBrowser class categoriesFor: #textFont!accessing!public! !
!FileBrowser class categoriesFor: #textFont:!accessing!public! !
!FileBrowser class categoriesFor: #warnings!accessing!public! !
!FileBrowser class categoriesFor: #warnings:!accessing!public! !

FileBrowserRuntimeSessionManager guid: (GUID fromString: '{6CC94E96-1D46-4749-A61E-B97AA9AAB3C9}')!
FileBrowserRuntimeSessionManager comment: ''!
!FileBrowserRuntimeSessionManager categoriesForClass!System-Support! !
!FileBrowserRuntimeSessionManager methodsFor!

main	
	FileBrowser show! !
!FileBrowserRuntimeSessionManager categoriesFor: #main!public! !

"Binary Globals"!

