'From Cuis 1.0 of 4 September 2009 [latest update: #290] on 18 September 2009 at 11:25:03 am'!

!Browser methodsFor: 'initialize-release' stamp: 'jmv 9/16/2009 10:43'!
buildMorphicClassList
	| myClassList |
	(myClassList := PluggableListMorph new)
		setProperty: #highlightSelector toValue: #highlightClassList:with:;
		model: self
		listGetter: #classList
		indexGetter: #classListIndex
		indexSetter: #classListIndex:
		menuGetter: #classListMenu:shifted:
		keystrokeAction: #classListKey:from:.
	myClassList borderWidth: 0.
	myClassList enableDragNDrop: false.
	myClassList doubleClickSelector: #browseSelectionInPlace.
	^myClassList! !

!Browser methodsFor: 'initialize-release' stamp: 'jmv 9/17/2009 23:35'!
buildMorphicMessageCatList
	| myMessageCatList |
	(myMessageCatList := PluggableMessageCategoryListMorph new)
		setProperty: #highlightSelector
			toValue: #highlightMessageCategoryList:with:;
		model: self
		listGetter: #messageCategoryList
		indexGetter: #messageCategoryListIndex
		indexSetter: #messageCategoryListIndex:
		menuGetter: #messageCategoryMenu:
		keystrokeAction: #arrowKey:from:
		rawListGetter: #rawMessageCategoryList.
	myMessageCatList enableDragNDrop: false.
	^myMessageCatList! !

!Browser methodsFor: 'initialize-release' stamp: 'jmv 9/16/2009 10:43'!
buildMorphicMessageList
	"Build a morphic message list, with #messageList as its list-getter"

	| aListMorph |
	(aListMorph := PluggableListMorph new)
		setProperty: #highlightSelector toValue: #highlightMessageList:with:;
		model: self
		listGetter: #messageList
		indexGetter: #messageListIndex
		indexSetter: #messageListIndex:
		menuGetter: #messageListMenu:shifted:
		keystrokeAction: #messageListKey:from:.
	aListMorph enableDragNDrop: false.
	aListMorph menuTitleSelector: #messageListSelectorTitle.
	^aListMorph! !

!Browser methodsFor: 'initialize-release' stamp: 'jmv 9/16/2009 10:44'!
buildMorphicSystemCatList
	| dragNDropFlag myCatList |
	dragNDropFlag := false.
	(myCatList := PluggableListMorph new)
		setProperty: #highlightSelector toValue: #highlightSystemCategoryList:with:;
		model: self
		listGetter: #systemCategoryList
		indexGetter: #systemCategoryListIndex
		indexSetter: #systemCategoryListIndex:
		menuGetter: #systemCategoryMenu:
		keystrokeAction: #systemCatListKey:from:.
	myCatList enableDragNDrop: dragNDropFlag.
	^myCatList! !

!Browser methodsFor: 'initialize-release' stamp: 'jmv 9/18/2009 11:03'!
openAsMorphClassEditing: editString 
	"Create a pluggable version a Browser on just a single class."

	| window dragNDropFlag hSepFrac switchHeight mySingletonClassList switches c |
	window := SystemWindow new model: self.
	dragNDropFlag := false.
	hSepFrac := 0.3.
	switchHeight _ StrikeFont default height + 10.
	mySingletonClassList := PluggableListMorph 
				model: self
				listGetter: #classListSingleton
				indexGetter: #indexIsOne
				indexSetter: #indexIsOne:
				menuGetter: #classListMenu:shifted:
				keystrokeAction: #classListKey:from:.
	mySingletonClassList enableDragNDrop: dragNDropFlag.
	self 
		addLowerPanesTo: window
		at: (0 @ hSepFrac corner: 1 @ 1)
		with: editString.
	window addMorph: mySingletonClassList
		fullFrame: (LayoutFrame fractions: (0 @ 0 corner: 0.5 @ 0)
				offsets: (0 @ 0 corner: 0 @ switchHeight)).
	switches _ self buildMorphicSwitches.
	c _ switches color.
	window addMorph: switches
		fullFrame: (LayoutFrame fractions: (0.5 @ 0 corner: 1.0 @ 0)
				offsets: (0 @ 0 corner: 0 @ switchHeight)).
	switches color: c.
	window addMorph: self buildMorphicMessageCatList
		fullFrame: (LayoutFrame fractions: (0 @ 0 corner: 0.5 @ hSepFrac)
				offsets: (0 @ switchHeight corner: 0 @ 0)).
	window addMorph: self buildMorphicMessageList
		fullFrame: (LayoutFrame fractions: (0.5 @ 0 corner: 1.0 @ hSepFrac)
				offsets: (0 @ switchHeight corner: 0 @ 0)).
	window setUpdatablePanesFrom: #(#messageCategoryList #messageList).
	^window! !

!Browser methodsFor: 'initialize-release' stamp: 'jmv 9/18/2009 11:03'!
openAsMorphMessageEditing: editString 
	"Create a pluggable version a Browser that shows just one message"

	| window mySingletonMessageList verticalOffset nominalFractions |
	window := SystemWindow new model: self.
	mySingletonMessageList := PluggableListMorph 
				model: self
				listGetter: #messageListSingleton
				indexGetter: #indexIsOne
				indexSetter: #indexIsOne:
				menuGetter: #messageListMenu:shifted:
				keystrokeAction: #messageListKey:from:.
	mySingletonMessageList enableDragNDrop: false.
	verticalOffset := 25.
	nominalFractions := 0 @ 0 corner: 1 @ 0.
	window addMorph: mySingletonMessageList
		fullFrame: (LayoutFrame fractions: nominalFractions
				offsets: (0 @ 0 corner: 0 @ verticalOffset)).
	verticalOffset := self 
				addOptionalAnnotationsTo: window
				at: nominalFractions
				plus: verticalOffset.
	verticalOffset := self 
				addOptionalButtonsTo: window
				at: nominalFractions
				plus: verticalOffset.
	window addMorph: (self buildMorphicCodePaneWith: editString)
		fullFrame: (LayoutFrame fractions: (0 @ 0 corner: 1 @ 1)
				offsets: (0 @ verticalOffset corner: 0 @ 0)).
	^window! !

!Browser methodsFor: 'initialize-release' stamp: 'jmv 9/18/2009 11:05'!
openAsMorphMsgCatEditing: editString 
	"Create a pluggable version a Browser on just a message category."

	| window hSepFrac |
	window := SystemWindow new model: self.
	hSepFrac := 0.3.
	window 
		addMorph: ((PluggableListMorph 
				model: self
				listGetter: #messageCatListSingleton
				indexGetter: #indexIsOne
				indexSetter: #indexIsOne:
				menuGetter: #messageCategoryMenu:) 
					enableDragNDrop: false)
		fullFrame: (LayoutFrame fractions: (0 @ 0 corner: 1 @ 0)
				offsets: (0 @ 0 corner: 0 @ 25)).
	window addMorph: self buildMorphicMessageList
		fullFrame: (LayoutFrame fractions: (0 @ 0 corner: 1 @ hSepFrac)
				offsets: (0 @ 25 corner: 0 @ 0)).
	self 
		addLowerPanesTo: window
		at: (0 @ hSepFrac corner: 1 @ 1)
		with: editString.
	window setUpdatablePanesFrom: #(#messageCatListSingleton #messageList).
	^window! !

!Browser methodsFor: 'initialize-release' stamp: 'jmv 9/18/2009 11:06'!
openAsMorphSysCatEditing: editString 
	"Create a pluggable version of all the views for a Browser, including views and controllers."

	| window hSepFrac switchHeight mySingletonList nextOffsets |
	window := SystemWindow new model: self.
	hSepFrac := 0.3.
	switchHeight := Preferences standardCodeFont height + 4.
	mySingletonList := PluggableListMorph 
				model: self
				listGetter: #systemCategorySingleton
				indexGetter: #indexIsOne
				indexSetter: #indexIsOne:
				menuGetter: #systemCatSingletonMenu:
				keystrokeAction: #systemCatSingletonKey:from:.
	mySingletonList enableDragNDrop: false.
	mySingletonList hideScrollBarsIndefinitely.
	window addMorph: mySingletonList
		fullFrame: (LayoutFrame fractions: (0 @ 0 corner: 1 @ 0)
				offsets: (0 @ 0 corner: 0 @ switchHeight)).
	self 
		addClassAndSwitchesTo: window
		at: (0 @ 0 corner: 0.3333 @ hSepFrac)
		plus: switchHeight.
	nextOffsets := 0 @ switchHeight corner: 0 @ 0.
	window addMorph: self buildMorphicMessageCatList
		fullFrame: (LayoutFrame 
				fractions: (0.3333 @ 0 corner: 0.6666 @ hSepFrac)
				offsets: nextOffsets).
	window addMorph: self buildMorphicMessageList
		fullFrame: (LayoutFrame fractions: (0.6666 @ 0 corner: 1 @ hSepFrac)
				offsets: nextOffsets).
	self 
		addLowerPanesTo: window
		at: (0 @ hSepFrac corner: 1 @ 1)
		with: editString.
	window 
		setUpdatablePanesFrom: #(#classList #messageCategoryList #messageList).
	^window! !


!ChangeList methodsFor: 'initialization-release' stamp: 'jmv 9/16/2009 11:17'!
openAsMorphName: labelString multiSelect: multiSelect 
	"Open a morphic view for the messageSet, whose label is labelString. 
	The listView may be either single or multiple selection type"
	| window listHeight listPane |
	listHeight _ 0.4.
	window _ (SystemWindow labelled: labelString)
				model: self.
	listPane _ multiSelect
				ifTrue: [PluggableListMorphOfMany
						model: self
						listGetter: #list
						primarySelectionGetter: #listIndex
						primarySelectionSetter: #toggleListIndex:
						listSelectionGetter: #listSelectionAt:
						listSelectionSetter: #listSelectionAt:put:
						menuGetter: (self showsVersions
								ifTrue: [#versionsMenu:]
								ifFalse: [#changeListMenu:])]
				ifFalse: [PluggableListMorph
						model: self
						listGetter: #list
						indexGetter: #listIndex
						indexSetter: #toggleListIndex:
						menuGetter: (self showsVersions
								ifTrue: [#versionsMenu:]
								ifFalse: [#changeListMenu:])].
	listPane keystrokeActionSelector: #changeListKey:from:.
	window
		addMorph: listPane
		frame: (0 @ 0 extent: 1 @ listHeight).
	self
		addLowerPanesTo: window
		at: (0 @ listHeight corner: 1 @ 1)
		with: nil.
	^ window openInWorld! !


!ChangeSorter methodsFor: 'creation' stamp: 'jmv 9/16/2009 10:56'!
openAsMorphIn: window rect: rect
	"Add a set of change sorter views to the given top view offset by the given amount. To create a single change sorter, call this once with an offset of 0@0. To create a dual change sorter, call it twice with offsets of 0@0 and 0.5@0."

	| csListHeight msgListHeight csMsgListHeight |
	contents _ ''.
	csListHeight _ 0.25.
	msgListHeight _ 0.25.
	csMsgListHeight _ csListHeight + msgListHeight.
	self addDependent: window.		"so it will get changed: #relabel"

	window addMorph: ((PluggableListMorphByItem 
				model: self
				listGetter: #changeSetList
				indexGetter: #currentCngSet
				indexSetter: #showChangeSetNamed:
				menuGetter: #changeSetMenu:shifted:
				keystrokeAction: #changeSetListKey:from:)
			autoDeselect: false)
		frame: (((0@0 extent: 0.5@csListHeight)
			scaleBy: rect extent) translateBy: rect origin).

	window addMorph: (PluggableListMorphByItem 
				model: self
				listGetter: #classList
				indexGetter: #currentClassName
				indexSetter: #currentClassName:
				menuGetter: #classListMenu:shifted:
				keystrokeAction: #classListKey:from:)
		frame: (((0.5@0 extent: 0.5@csListHeight)
			scaleBy: rect extent) translateBy: rect origin).

	window addMorph: (PluggableListMorphByItem 
				model: self
				listGetter: #messageList
				indexGetter: #currentSelector
				indexSetter: #currentSelector:
				menuGetter: #messageMenu:shifted:
				keystrokeAction: #messageListKey:from:)
		frame: (((0@csListHeight extent: 1@msgListHeight)
			scaleBy: rect extent) translateBy: rect origin).

	 self addLowerPanesTo: window
		at: (((0@csMsgListHeight corner: 1@1) scaleBy: rect extent) translateBy: rect origin)
		with: nil.! !


!ChangeSetBrowser methodsFor: 'initialization' stamp: 'jmv 9/16/2009 10:47'!
openAsMorphIn: window rect: rect
	"Add a set of changeSetBrowser views to the given top view offset by the given amount"

	| aHeight |
	contents _ ''.
	aHeight _ 0.25.
	self addDependent: window.		"so it will get changed: #relabel"


	window addMorph: (PluggableListMorphByItem 
				model: self
				listGetter: #classList
				indexGetter: #currentClassName
				indexSetter: #currentClassName:
				menuGetter: #classListMenu:shifted:
				keystrokeAction: #classListKey:from:)
		frame: (((0.0@0 extent: 0.5 @ aHeight)
			scaleBy: rect extent) translateBy: rect origin).

	window addMorph: (PluggableListMorphByItem 
				model: self
				listGetter: #messageList
				indexGetter: #currentSelector
				indexSetter: #currentSelector:
				menuGetter: #messageMenu:shifted:
				keystrokeAction: #messageListKey:from:)
		frame: (((0.5@0 extent: 0.5 @ aHeight)
			scaleBy: rect extent) translateBy: rect origin).

	 self addLowerPanesTo: window
		at: (((0@aHeight corner: 1@1) scaleBy: rect extent) translateBy: rect origin)
		with: nil! !


!Debugger methodsFor: 'initialize' stamp: 'jmv 9/16/2009 10:49'!
openFullMorphicLabel: aLabelString
	"Open a full morphic debugger with the given label"

	| window aListMorph oldContextStackIndex |
	oldContextStackIndex _ contextStackIndex.
	self expandStack. "Sets contextStackIndex to zero."

	window _ (SystemWindow labelled: aLabelString) model: self.
	aListMorph _ PluggableListMorph
		model: self 
		listGetter: #contextStackList
		indexGetter: #contextStackIndex
		indexSetter: #toggleContextStackIndex:
		menuGetter: #contextStackMenu:shifted:
		keystrokeAction: #contextStackKey:from:.
	aListMorph menuTitleSelector: #messageListSelectorTitle.
	window addMorph: aListMorph
		frame: (0@0 corner: 1@0.25).

	self addLowerPanesTo: window at: (0@0.25 corner: 1@0.8) with: nil.

	window addMorph: (
		PluggableListMorph new
			doubleClickSelector: #inspectSelection;
			model: self receiverInspector
			listGetter: #fieldList
			indexGetter: #selectionIndex 
			indexSetter: #toggleIndex:
			menuGetter: #fieldListMenu: 
			keystrokeAction: #inspectorKey:from:)
		frame: (0@0.8 corner: 0.2@1).
	window addMorph: (PluggableTextMorph 
			on: self receiverInspector
			editorClass: self receiverInspector editorClass
			text: #contents 
			accept: #accept:
			readSelection: #contentsSelection 
			menu: #paneMenu:shifted:editorClass:)
		frame: (0.2@0.8 corner: 0.5@1).
	window addMorph: (
		PluggableListMorph new
			doubleClickSelector: #inspectSelection;
			model: self contextVariablesInspector 
			listGetter: #fieldList
			indexGetter: #selectionIndex 
			indexSetter: #toggleIndex:
			menuGetter: #fieldListMenu: 
			keystrokeAction: #inspectorKey:from:)
		frame: (0.5@0.8 corner: 0.7@1).
	window addMorph: (PluggableTextMorph 
			on: self contextVariablesInspector
			editorClass: self contextVariablesInspector editorClass
			text: #contents 
			accept: #accept:
			readSelection: #contentsSelection 
			menu: #paneMenu:shifted:editorClass:)
		frame: (0.7@0.8 corner: 1@1).
	window openInWorld.
	self toggleContextStackIndex: oldContextStackIndex.
	^ window ! !

!Debugger methodsFor: 'context stack menu' stamp: 'jmv 9/16/2009 10:48'!
buildMorphicNotifierLabelled: label message: messageString 
	| notifyPane window contentTop extentToUse |
	self expandStack.
	window := (PreDebugWindow labelled: label) model: self.
	contentTop := 0.2.
	extentToUse := 650 @ 320.	"nice and wide to show plenty of the error msg"
	window addMorph: (self buttonRowForPreDebugWindow: window)
		frame: (0 @ 0 corner: 1 @ contentTop).
	messageString notNil 
		ifFalse: [
			notifyPane := PluggableListMorph 
						model: self
						listGetter: #contextStackList
						indexGetter: #contextStackIndex
						indexSetter: #debugAt:
						menuGetter: nil
						keystrokeAction: nil]
		ifTrue: [
			notifyPane := PluggableTextMorph 
						on: self
						editorClass: self editorClass
						text: nil
						accept: nil
						readSelection: nil
						menu: #debugProceedMenu:.
			notifyPane
				editString: (self preDebugNotifierContentsFrom: messageString);
				askBeforeDiscardingEdits: false].
	window addMorph: notifyPane frame: (0 @ contentTop corner: 1 @ 1).
	^window openInWorldExtent: extentToUse! !


!FileContentsBrowser methodsFor: 'creation' stamp: 'jmv 9/16/2009 11:02'!
openAsMorph
	"Create a pluggable version of all the views for a Browser, including views and controllers."
	| window aListExtent next mySingletonList |
	window _ SystemWindow new model: self.
	self packages size = 1
		ifTrue: [
			aListExtent _ 0.333333 @ 0.34.
			self systemCategoryListIndex: 1.
			mySingletonList _ PluggableListMorph 
					model: self 
					listGetter: #systemCategorySingleton
					indexGetter: #indexIsOne 
					indexSetter: #indexIsOne:
					menuGetter: #packageListMenu:
					keystrokeAction: #packageListKey:from:.
			mySingletonList hideScrollBarsIndefinitely.
			window addMorph: mySingletonList frame: (0@0 extent: 1.0@0.06).
			next := 0@0.06]
		ifFalse: [
			aListExtent _ 0.25 @ 0.4.
			window addMorph: (PluggableListMorph 
					model: self 
					listGetter: #systemCategoryList
					indexGetter: #systemCategoryListIndex 
					indexSetter: #systemCategoryListIndex:
					menuGetter: #packageListMenu:
					keystrokeAction: #packageListKey:from:)
				frame: (0@0 extent: aListExtent).
			next := aListExtent x @ 0].

	self addClassAndSwitchesTo: window at: (next extent: aListExtent).

	next := next + (aListExtent x @ 0).
	window addMorph: (PluggableListMorph 
			model: self 
			listGetter: #messageCategoryList
			indexGetter: #messageCategoryListIndex 
			indexSetter: #messageCategoryListIndex:
			menuGetter: #messageCategoryMenu:)
		frame: (next extent: aListExtent).
	next := next + (aListExtent x @ 0).
	window addMorph: (PluggableListMorph 
			model: self 
			listGetter: #messageList
			indexGetter: #messageListIndex 
			indexSetter: #messageListIndex:
			menuGetter: #messageListMenu:
			keystrokeAction: #messageListKey:from:)
		frame: (next extent: aListExtent).

	self addLowerPanesTo: window at: (0@0.4 corner: 1@1) with: nil.
	^ window
! !


!FileList class methodsFor: 'instance creation' stamp: 'jmv 9/18/2009 11:10'!
addButtonsAndFileListPanesTo: window at: upperFraction plus: offset forFileList: aFileList 
	| fileListMorph column buttonHeight fileListTop divider dividerDelta buttons |
	fileListMorph _ PluggableListMorph
				model: aFileList
				listGetter: #fileList
				indexGetter: #fileListIndex
				indexSetter: #fileListIndex:
				menuGetter: #fileListMenu:.
	fileListMorph enableDrag: true; enableDrop: false.
	aFileList wantsOptionalButtons
		ifTrue: [
			buttons _ aFileList optionalButtonRow.
			divider _ BorderedSubpaneDividerMorph forBottomEdge.
			dividerDelta _ 0.
			Preferences alternativeWindowLook
				ifTrue: [
					buttons color: Color transparent.
					divider extent: 4 @ 4;
						 color: Color transparent;
						 borderColor: #raised;
						 borderWidth: 2.
					fileListMorph borderColor: Color transparent.
					dividerDelta _ 3].
			column _ AlignmentMorph proportional.
			buttonHeight _ self defaultButtonPaneHeight.
			column
				addMorph: buttons
				fullFrame: (LayoutFrame
						fractions: (0 @ 0 corner: 1 @ 0)
						offsets: (0 @ 0 corner: 0 @ buttonHeight)).
			column
				addMorph: divider
				fullFrame: (LayoutFrame
						fractions: (0 @ 0 corner: 1 @ 0)
						offsets: (0 @ buttonHeight corner: 0 @ buttonHeight + dividerDelta)).
			column
				addMorph: fileListMorph
				fullFrame: (LayoutFrame
						fractions: (0 @ 0 corner: 1 @ 1)
						offsets: (0 @ buttonHeight + dividerDelta corner: 0 @ 0)).
			window
				addMorph: column
				fullFrame: (LayoutFrame
						fractions: upperFraction
						offsets: (0 @ offset corner: 0 @ 0)).
			Preferences alternativeWindowLook
				ifTrue: [column borderWidth: 2]
				ifFalse: [column borderWidth: 0]]
		ifFalse: [
			fileListTop _ 0.
			window
				addMorph: fileListMorph
				frame: (0.3 @ fileListTop corner: 1 @ 0.3)].! !

!FileList class methodsFor: 'instance creation' stamp: 'jmv 9/18/2009 11:10'!
addVolumesAndPatternPanesTo: window at: upperFraction plus: offset forFileList: aFileList 
	| column patternHeight volumeListMorph patternMorph divider dividerDelta |
	column _ AlignmentMorph proportional.
	patternHeight _ 25.
	volumeListMorph _ (PluggableListMorph
				model: aFileList
				listGetter: #volumeList
				indexGetter: #volumeListIndex
				indexSetter: #volumeListIndex:
				menuGetter: #volumeMenu:)
				autoDeselect: false.
	volumeListMorph enableDrag: false; enableDrop: true.
	patternMorph _ PluggableTextMorph
				on: aFileList
				editorClass: aFileList editorClass
				text: #pattern
				accept: #pattern:.
	patternMorph acceptOnCR: true.
	patternMorph hideScrollBarsIndefinitely.
	divider _ BorderedSubpaneDividerMorph new.
	dividerDelta _ 0.
	Preferences alternativeWindowLook
		ifTrue: [
			divider
				extent: 4 @ 4;
				color: Color transparent;
				borderColor: #raised;
				borderWidth: 2.
			volumeListMorph borderColor: Color transparent.
			patternMorph borderColor: Color transparent.
			dividerDelta _ 3].
	column
		addMorph: (volumeListMorph autoDeselect: false)
		fullFrame: (LayoutFrame
				fractions: (0 @ 0 corner: 1 @ 1)
				offsets: (0 @ 0 corner: 0 @ patternHeight negated - dividerDelta)).
	column
		addMorph: divider
		fullFrame: (LayoutFrame
				fractions: (0 @ 1 corner: 1 @ 1)
				offsets: (0 @ patternHeight negated - dividerDelta corner: 0 @ patternHeight negated)).
	column
		addMorph: patternMorph
		fullFrame: (LayoutFrame
				fractions: (0 @ 1 corner: 1 @ 1)
				offsets: (0 @ patternHeight negated corner: 0 @ 0)).
	window
		addMorph: column
		fullFrame: (LayoutFrame
				fractions: upperFraction
				offsets: (0 @ offset corner: 0 @ 0)).
	Preferences alternativeWindowLook
		ifTrue: [column borderWidth: 2] ifFalse: [column borderWidth: 0]! !


!FileList2 methodsFor: 'user interface' stamp: 'jmv 9/16/2009 10:51'!
morphicDirectoryTreePaneFiltered: aSymbol
	^(SimpleHierarchicalListMorph 
		model: self
		listGetter: aSymbol
		indexGetter: #currentDirectorySelected
		indexSetter: #setSelectedDirectoryTo:
		menuGetter: #volumeMenu:
		keystrokeAction: nil)
			autoDeselect: false;
			enableDrag: false;
			enableDrop: true;
			yourself
		
! !

!FileList2 methodsFor: 'user interface' stamp: 'jmv 9/16/2009 11:02'!
morphicFileListPane

	^(PluggableListMorph 
		model: self 
		listGetter: #fileList 
		indexGetter: #fileListIndex
		indexSetter: #fileListIndex: 
		menuGetter: #fileListMenu:)
			enableDrag: true;
			enableDrop: false;
			yourself

! !


!Inspector class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 10:51'!
openAsMorphOn: anObject withLabel: aLabel
	"(Inspector openAsMorphOn: SystemOrganization) openInMVC"
	| window inspector |
	inspector _ self inspect: anObject.
	window _ (SystemWindow labelled: aLabel) model: inspector.
	window addMorph: (
		PluggableListMorph new
			doubleClickSelector: #inspectSelection;
			model: inspector 
			listGetter: #fieldList
			indexGetter: #selectionIndex
			indexSetter: #toggleIndex:
			menuGetter: ((inspector isMemberOf: DictionaryInspector)
					ifTrue: [#dictionaryMenu:]
					ifFalse: [#fieldListMenu:])
			keystrokeAction: #inspectorKey:from:)
		frame: (0@0 corner: self horizontalDividerProportion @ self verticalDividerProportion).
	window addMorph: (PluggableTextMorph
			on: inspector 
			editorClass: inspector editorClass 
			text: #contents 
			accept: #accept:
			readSelection: #contentsSelection 
			menu: #paneMenu:shifted:editorClass:)
		frame: (self horizontalDividerProportion @0 corner: 1@self verticalDividerProportion).
	window addMorph: ((PluggableTextMorph 
			on: inspector 
			editorClass: inspector editorClass
			text: #trash 
			accept: #trash:
			readSelection: #contentsSelection 
			menu: #paneMenu:shifted:editorClass:)
					askBeforeDiscardingEdits: false)
		frame: (0@self verticalDividerProportion corner: 1@1).
	window setUpdatablePanesFrom: #(fieldList).
	window position: 16@0.  "Room for scroll bar."
	^ window! !


!InspectorBrowser class methodsFor: 'as yet unclassified' stamp: 'jmv 9/16/2009 11:03'!
openAsMorphOn: anObject
	"(InspectorBrowser openAsMorphOn: SystemOrganization) openInMVC"
	| window inspector |
	inspector _ self inspect: anObject.
	window _ (SystemWindow labelled: anObject defaultLabelForInspector)
				model: inspector.

	window addMorph: (PluggableListMorph 
			model: inspector 
			listGetter: #fieldList
			indexGetter: #selectionIndex 
			indexSetter: #toggleIndex: 
			menuGetter: #fieldListMenu:)
		frame: (0@0 corner: 0.3@0.5).
	window addMorph: (PluggableTextMorph 
			on: inspector 
			editorClass: inspector editorClass 
			text: #contents 
			accept: #accept:
			readSelection: nil 
			menu: #paneMenu:shifted:editorClass:)
		frame: (0.3@0 corner: 1.0@0.5).
	window addMorph: (PluggableListMorph 
			model: inspector 
			listGetter: #msgList
			indexGetter: #msgListIndex 
			indexSetter: #msgListIndex: 
			menuGetter: #msgListMenu:)
		frame: (0@0.5 corner: 0.3@1.0).
	window addMorph: (PluggableTextMorph 
			on: inspector 
			editorClass: inspector editorClass 
			text: #msgText 
			accept: #msgAccept:from:
			readSelection: nil 
			menu: #msgPaneMenu:shifted:)
		frame: (0.3@0.5 corner: 1.0@1.0).
	
	window setUpdatablePanesFrom: #(fieldList msgList).
	window position: 16@0.  "Room for scroll bar."
	^ window! !


!LazyListMorph methodsFor: 'drawing' stamp: 'jmv 9/16/2009 14:02'!
display: item  atRow: row on: canvas
	"display the given item at row row"
	| drawBounds f |
	drawBounds _ self drawBoundsForRow: row.
	drawBounds _ drawBounds intersect: self bounds.
	f _ item isText ifTrue: [ font emphasized: (item emphasisAt: 1) ] ifFalse: [ font ].
	canvas drawString: item in: drawBounds font: f color: (self colorForRow: row)! !


!MessageSet methodsFor: 'private' stamp: 'jmv 9/16/2009 10:53'!
buildMorphicMessageList
	"Build my message-list object in morphic"

	| aListMorph |
	aListMorph := PluggableListMorph new.
	aListMorph
		setProperty: #highlightSelector toValue: #highlightMessageList:with:;
		setProperty: #itemConversionMethod toValue: #asStringOrText.
	aListMorph 
		model: self
		listGetter: #messageList
		indexGetter: #messageListIndex
		indexSetter: #messageListIndex:
		menuGetter: #messageListMenu:shifted:
		keystrokeAction: #messageListKey:from:.
	aListMorph enableDragNDrop: false.
	aListMorph menuTitleSelector: #messageListSelectorTitle.
	^aListMorph! !


!MessageNames methodsFor: 'initialization' stamp: 'jmv 9/16/2009 10:52'!
inMorphicWindowWithInitialSearchString: initialString
	"Answer a morphic window with the given initial search string, nil if none"

"MessageNames openMessageNames"

	| window selectorListView firstDivider secondDivider horizDivider typeInPane searchButton plugTextMor |
	window _ (SystemWindow labelled: 'Message Names') model: self.
	firstDivider _ 0.07.
	secondDivider _ 0.5.
	horizDivider _ 0.5.
	typeInPane _ AlignmentMorph proportional height: 14.

	plugTextMor _ PluggableTextMorph 
		on: self
		editorClass: self editorClass
		text: #searchString 
		accept: #searchString:notifying:
		readSelection: nil 
		menu: nil.
	plugTextMor setProperty: #alwaysAccept toValue: true.
	plugTextMor askBeforeDiscardingEdits: false.
	plugTextMor acceptOnCR: true.
	plugTextMor setTextColor: Color brown.
	plugTextMor hideScrollBarsIndefinitely.
	plugTextMor setTextMorphToSelectAllOnMouseEnter.

	searchButton _ SimpleButtonMorph new 
		target: self;
		beTransparent;
		label: 'Search';
		actionSelector: #doSearchFrom:;
		arguments: {plugTextMor}.
	searchButton setBalloonText: 'Type some letters into the pane at right, and then press this Search button (or hit RETURN) and all method selectors that match what you typed will appear in the list pane below.  Click on any one of them, and all the implementors of that selector will be shown in the right-hand pane, and you can view and edit their code without leaving this tool.'.

	typeInPane addInProportionalRow: { searchButton. plugTextMor. }.
	initialString isEmptyOrNil ifFalse:
		[plugTextMor setText: initialString].

	window addMorph: typeInPane frame: (0@0 corner: horizDivider @ firstDivider).

	selectorListView _ PluggableListMorph 
		model: self
		listGetter: #selectorList
		indexGetter: #selectorListIndex
		indexSetter: #selectorListIndex:
		menuGetter: #selectorListMenu:
		keystrokeAction: #selectorListKey:from:.
	selectorListView menuTitleSelector: #selectorListMenuTitle.
	window addMorph: selectorListView frame: (0 @ firstDivider corner: horizDivider @ secondDivider).

	window addMorph: self buildMorphicMessageList frame: (horizDivider @ 0 corner: 1@ secondDivider).

	self 
		addLowerPanesTo: window 
		at: (0 @ secondDivider corner: 1@1) 
		with: nil.

	initialString isEmptyOrNil ifFalse:
		[self searchString: initialString notifying: nil].
	^ window! !


!ObjectExplorer methodsFor: 'accessing' stamp: 'jmv 9/16/2009 10:53'!
explorerFor: anObject 
	| window listMorph |
	rootObject := anObject.
	window := (SystemWindow labelled: (rootObject printStringLimitedTo: 64)) model: self.
	window addMorph: (listMorph := SimpleHierarchicalListMorph 
						model: self
						listGetter: #getList
						indexGetter: #getCurrentSelection
						indexSetter: #noteNewSelection:
						menuGetter: #genericMenu:
						keystrokeAction: #explorerKey:from:)
		frame: (0 @ 0 corner: 1 @ 0.8).
	window 
		addMorph: ((PluggableTextMorph 
				on: self
				editorClass: self editorClass
				text: #trash
				accept: #trash:
				readSelection: #contentsSelection
				menu: #paneMenu:shifted:editorClass:) askBeforeDiscardingEdits: false)
		frame: (0 @ 0.8 corner: 1 @ 1).
	listMorph autoDeselect: false.
	^window! !


!PackagePaneBrowser methodsFor: 'initialize-release' stamp: 'jmv 9/18/2009 11:07'!
openAsMorphEditing: editString 
	"Create a pluggable version of all the views for a Browser, including 
	views and controllers."
	"PackagePaneBrowser openBrowser"

	| listHeight window |
	listHeight _ 0.4.
	window _ SystemWindow new model: self.

"The method SystemWindow>>addMorph:fullFrame: checks scrollBarsOnRight, then adds the morph at the back if true, otherwise it is added in front. But flopout hScrollbars need the lowerpanes to be behind the upper ones in the draw order. Hence the value of scrollBarsOnRight affects the order in which the lowerpanes are added. "
	Preferences scrollBarsOnRight ifFalse: [
		self 
			addLowerPanesTo: window 
			at: (0@listHeight corner: 1@1) 
			with: editString].

	window
		addMorph: (PluggableListMorph
				model: self
				listGetter: #packageList
				indexGetter: #packageListIndex
				indexSetter: #packageListIndex:
				menuGetter: #packageMenu:
				keystrokeAction: #packageListKey:from:)
		frame: (0 @ 0 extent: 0.15 @ listHeight).
	window
		addMorph: self buildMorphicSystemCatList
		frame: (0.15 @ 0 extent: 0.2 @ listHeight).
	self
		addClassAndSwitchesTo: window
		at: (0.35 @ 0 extent: 0.25 @ listHeight)
		plus: 0.
	window
		addMorph: self buildMorphicMessageCatList
		frame: (0.6 @ 0 extent: 0.15 @ listHeight).
	window
		addMorph: self buildMorphicMessageList
		frame: (0.75 @ 0 extent: 0.25 @ listHeight).
		
	Preferences scrollBarsOnRight ifTrue: [
		self
			addLowerPanesTo: window
			at: (0 @ listHeight corner: 1 @ 1)
			with: editString ].
	window setUpdatablePanesFrom: #(#packageList #systemCategoryList #classList #messageCategoryList #messageList ).
	^ window! !


!PluggableListMorph methodsFor: 'initialization' stamp: 'jmv 9/16/2009 10:40'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel keystrokeAction: keyActionSel

	self model: anObject.
	getListSelector _ getListSel.
	getIndexSelector _ getSelectionSel.
	setIndexSelector _ setSelectionSel.
	getMenuSelector _ getMenuSel.
	keystrokeActionSelector _ keyActionSel.
	autoDeselect _ true.
	self borderWidth: 1.
	self updateList.
	self selectionIndex: self getCurrentSelectionIndex.
	self initForKeystrokes! !


!PluggableListMorph class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 11:05'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel
	"Create a 'pluggable' list view on the given model parameterized by the given message selectors. See ListView>>aboutPluggability comment."

	^ self new
		model: anObject 
		listGetter: getListSel 
		indexGetter: getSelectionSel 
		indexSetter: setSelectionSel 
		menuGetter: nil
		keystrokeAction: #arrowKey:from:		"default"! !

!PluggableListMorph class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 11:09'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel
	"Create a 'pluggable' list view on the given model parameterized by the given message selectors."

	^ self new
		model: anObject
		listGetter: getListSel 
		indexGetter: getSelectionSel 
		indexSetter: setSelectionSel 
		menuGetter: getMenuSel
		keystrokeAction: #arrowKey:from:		"default"! !

!PluggableListMorph class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 10:41'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel keystrokeAction: keyActionSel
	"Create a 'pluggable' list view on the given model parameterized by the given message selectors."

	^ self new
		model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel keystrokeAction: keyActionSel! !


!PluggableListMorphOfMany methodsFor: 'initialization' stamp: 'jmv 9/16/2009 11:13'!
model: anObject listGetter: listSel primarySelectionGetter: getSelectionSel primarySelectionSetter: setSelectionSel listSelectionGetter: getListSel listSelectionSetter: setListSel menuGetter: getMenuSel keystrokeAction: keyActionSel
	"setup a whole load of pluggability options"
	getSelectionListSelector _ getListSel.
	setSelectionListSelector _ setListSel.
	self 
		model: anObject 
		listGetter: listSel 
		indexGetter: getSelectionSel 
		indexSetter: setSelectionSel 
		menuGetter: getMenuSel 
		keystrokeAction: keyActionSel
! !


!PluggableListMorphOfMany class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 11:16'!
model: anObject listGetter: listSel primarySelectionGetter: getSelectionSel primarySelectionSetter: setSelectionSel listSelectionGetter: getListSel listSelectionSetter: setListSel menuGetter: getMenuSel

	^ self new
		model: anObject
		listGetter: listSel
		primarySelectionGetter: getSelectionSel
		primarySelectionSetter: setSelectionSel
		listSelectionGetter: getListSel
		listSelectionSetter: setListSel
		menuGetter: getMenuSel
		keystrokeAction: #arrowKey:from:		"default"! !

!PluggableListMorphOfMany class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 11:16'!
model: anObject listGetter: listSel primarySelectionGetter: getSelectionSel primarySelectionSetter: setSelectionSel listSelectionGetter: getListSel listSelectionSetter: setListSel menuGetter: getMenuSel keystrokeAction: keyActionSel

	^ self new
		model: anObject
		listGetter: listSel
		primarySelectionGetter: getSelectionSel
		primarySelectionSetter: setSelectionSel
		listSelectionGetter: getListSel
		listSelectionSetter: setListSel
		menuGetter: getMenuSel
		keystrokeAction: keyActionSel! !


!PluggableMessageCategoryListMorph methodsFor: 'as yet unclassified' stamp: 'jmv 9/17/2009 23:33'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel keystrokeAction: keyActionSel rawListGetter: getRawSel
	self model: anObject.
	getListSelector _ getListSel.
	getIndexSelector _ getSelectionSel.
	setIndexSelector _ setSelectionSel.
	getMenuSelector _ getMenuSel.
	keystrokeActionSelector _ keyActionSel.
	autoDeselect _ true.
	self borderWidth: 1.
	getRawListSelector _ getRawSel.
	self updateList.
	self selectionIndex: self getCurrentSelectionIndex.
	self initForKeystrokes! !


!PluggableMessageCategoryListMorph class methodsFor: 'as yet unclassified' stamp: 'jmv 9/17/2009 23:33'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel keystrokeAction: keyActionSel rawListGetter: getRawSel
	^ self new model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel keystrokeAction: keyActionSel rawListGetter: getRawSel! !


!PointerFinder methodsFor: 'morphic ui' stamp: 'jmv 9/16/2009 10:54'!
open
	| window list |
	window _ (SystemWindow labelled: 'Pointer Finder')
		model: self.
	list _ PluggableListMorph new
		doubleClickSelector: #inspectObject;
		model: self
		listGetter: #pointerList
		indexGetter: #pointerListIndex
		indexSetter: #pointerListIndex:
		menuGetter: #menu:shifted:
		keystrokeAction: #arrowKey:from:.
	window addMorph: list frame: (0@0 extent: 1@1).
	list color: Color lightMagenta.
	window openInWorld! !


!Preferences class methodsFor: 'themes' stamp: 'jmv 9/16/2009 10:25'!
juans

	self setPreferencesFrom:

	#(
		(annotationPanes true)
		(balloonHelpEnabled false)
		(browseWithPrettyPrint false)
		(browserShowsPackagePane false)
		(caseSensitiveFinds true)
		(checkForSlips true)
		(cmdDotEnabled true)
		(collapseWindowsInPlace false)
		(diffsInChangeList true)
		(diffsWithPrettyPrint false)
		(fastDragWindowForMorphic true)
		(honorDesktopCmdKeys false)
		(inboardScrollbars true)
		(menuColorFromWorld false)
		(menuKeyboardControl true)
		(optionalButtons true)
		(extraDebuggerButtons true)
		(personalizedWorldMenu false)
		(restartAlsoProceeds false)
		(scrollBarsWithoutMenuButton true)
		(simpleMenus false)
		(smartUpdating true)
		(subPixelRenderFonts true)
		(thoroughSenders true)
	)! !


!ProcessBrowser methodsFor: 'views' stamp: 'jmv 9/16/2009 10:54'!
asPrototypeInWindow
	"Create a pluggable version of me, answer a window"

	| window aTextMorph |
	window _ SystemWindow new model: self.
	window
		addMorph: ((PluggableListMorph
				model: self
				listGetter: #processNameList
				indexGetter: #processListIndex
				indexSetter: #processListIndex:
				menuGetter: #processListMenu:
				keystrokeAction: #processListKey:from:)
				enableDragNDrop: false)
		frame: (0 @ 0 extent: 0.5 @ 0.5).
	window
		addMorph: ((PluggableListMorph
				model: self
				listGetter: #stackNameList
				indexGetter: #stackListIndex
				indexSetter: #stackListIndex:
				menuGetter: #stackListMenu:
				keystrokeAction: #stackListKey:from:)
				enableDragNDrop: false)
		frame: (0.5 @ 0.0 extent: 0.5 @ 0.5).
	aTextMorph _ PluggableTextMorph
				on: self
				editorClass: TextEditor
				text: #selectedMethod
				accept: nil
				readSelection: nil
				menu: nil.
	window
		addMorph: aTextMorph
		frame: (0 @ 0.5 corner: 1 @ 1).
	window setLabel: 'Process Browser'.
	^ window! !

!ProcessBrowser methodsFor: 'views' stamp: 'jmv 9/16/2009 10:55'!
openAsMorph
	"Create a pluggable version of me, answer a window"
	| window aTextMorph |
	window _ SystemWindow new
				model: self.

	deferredMessageRecipient _ WorldState.
	window
		addMorph: ((PluggableListMorph
				model: self
				listGetter: #processNameList
				indexGetter: #processListIndex
				indexSetter: #processListIndex:
				menuGetter: #processListMenu:
				keystrokeAction: #processListKey:from:)
				enableDragNDrop: false)
		frame: (0 @ 0 extent: 0.5 @ 0.5).
	window
		addMorph: ((PluggableListMorph
				model: self
				listGetter: #stackNameList
				indexGetter: #stackListIndex
				indexSetter: #stackListIndex:
				menuGetter: #stackListMenu:
				keystrokeAction: #stackListKey:from:)
				enableDragNDrop: false)
		frame: (0.5 @ 0.0 extent: 0.5 @ 0.5).
	aTextMorph _ PluggableTextMorph
				on: self
				editorClass: TextEditor
				text: #selectedMethod
				accept: nil
				readSelection: nil
				menu: nil.
	aTextMorph askBeforeDiscardingEdits: false.
	window
		addMorph: aTextMorph
		frame: (0 @ 0.5 corner: 1 @ 1).
	window setUpdatablePanesFrom: #(#processNameList #stackNameList ).
	(window setLabel: 'Process Browser') openInWorld.
	startedCPUWatcher ifTrue: [ self setUpdateCallbackAfter: 7 ].
	^ window! !


!SelectorBrowser methodsFor: 'as yet unclassified' stamp: 'jmv 9/16/2009 10:55'!
morphicWindow
	"Create a Browser that lets you type part of a selector, shows a list of selectors, shows the classes of the one you chose, and spawns a full browser on it.  Answer the window
	SelectorBrowser new open "

	| window typeInView selectorListView classListView |
	window := SystemWindow new model: self.
	selectorIndex := classListIndex := 0.
	typeInView := PluggableTextMorph 
				on: self
				editorClass: self editorClass
				text: #contents
				accept: #contents:notifying:
				readSelection: #contentsSelection
				menu: #paneMenu:shifted:editorClass:.
	typeInView acceptOnCR: true.
	typeInView hideScrollBarsIndefinitely.
	window addMorph: typeInView frame: (0 @ 0 corner: 0.5 @ 0.14).
	selectorListView := PluggableListMorph 
				model: self
				listGetter: #messageList
				indexGetter: #messageListIndex
				indexSetter: #messageListIndex:
				menuGetter: #selectorMenu:
				keystrokeAction: #messageListKey:from:.
	selectorListView menuTitleSelector: #selectorMenuTitle.
	window addMorph: selectorListView frame: (0 @ 0.14 corner: 0.5 @ 0.6).
	classListView := PluggableListMorph 
				model: self
				listGetter: #classList
				indexGetter: #classListIndex
				indexSetter: #classListIndex:
				menuGetter: nil
				keystrokeAction: #arrowKey:from:.
	classListView menuTitleSelector: #classListSelectorTitle.
	window addMorph: classListView frame: (0.5 @ 0 corner: 1 @ 0.6).
	window 
		addMorph: ((PluggableTextMorph 
				on: self
				editorClass: self editorClass
				text: #byExample
				accept: #byExample:
				readSelection: #contentsSelection
				menu: #paneMenu:shifted:editorClass:) askBeforeDiscardingEdits: false)
		frame: (0 @ 0.6 corner: 1 @ 1).
	window setLabel: 'Method Finder'.
	^window! !


!SimpleButtonMorph methodsFor: 'event handling' stamp: 'jmv 9/16/2009 11:36'!
mouseDown: evt

	| now dt |
	super mouseDown: evt.
	now _ Time millisecondClockValue.
	oldColor _ self fillStyle. 
	actWhen == #buttonDown
		ifTrue: [ self doButtonAction ]
		ifFalse: [ self updateVisualState: evt; refreshWorld ].
	dt _ Time millisecondClockValue - now max: 0.  "Time it took to do"
	dt < 200 ifTrue: [(Delay forMilliseconds: 200-dt) wait].
	self mouseStillDown: evt.! !


!SimpleHierarchicalListMorph methodsFor: 'initialization' stamp: 'jmv 9/16/2009 10:40'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel keystrokeAction: keyActionSel

	self model: anObject.
	getListSelector _ getListSel.
	getSelectionSelector _ getSelectionSel.
	setSelectionSelector _ setSelectionSel.
	getMenuSelector _ getMenuSel.
	keystrokeActionSelector _ keyActionSel.
	autoDeselect _ true.
	self borderWidth: 1.
	self list: self getList.! !


!SimpleHierarchicalListMorph class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 11:05'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel
	"Create a 'pluggable' list view on the given model parameterized by the given message selectors. See ListView>>aboutPluggability comment."

	^ self new
		model: anObject 
		listGetter: getListSel 
		indexGetter: getSelectionSel 
		indexSetter: setSelectionSel 
		menuGetter: nil
		keystrokeAction: #arrowKey:from:		"default"! !

!SimpleHierarchicalListMorph class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 10:59'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel
	"Create a 'pluggable' list view on the given model parameterized by the given message selectors."

	^ self new
		model: anObject l
		listGetter: getListSel 
		indexGetter: getSelectionSel 
		indexSetter: setSelectionSel 
		menuGetter: getMenuSel
		keystrokeAction: #arrowKey:from:		"default"! !

!SimpleHierarchicalListMorph class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 10:41'!
model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel keystrokeAction: keyActionSel
	"Create a 'pluggable' list view on the given model parameterized by the given message selectors."

	^ self new
		model: anObject listGetter: getListSel indexGetter: getSelectionSel indexSetter: setSelectionSel menuGetter: getMenuSel keystrokeAction: keyActionSel! !


!SyntaxError class methodsFor: 'instance creation' stamp: 'jmv 9/16/2009 11:04'!
buildMorphicViewOn: aSyntaxError
	"Answer an Morphic view on the given SyntaxError."
	| window |
	window _ (SystemWindow labelled: 'Syntax Error') model: aSyntaxError.

	window addMorph: (PluggableListMorph 
			model: aSyntaxError 
			listGetter: #list
			indexGetter: #listIndex 
			indexSetter: nil 
			menuGetter: #listMenu:)
		frame: (0@0 corner: 1@0.15).

	window addMorph: (PluggableTextMorph 
			on: aSyntaxError 
			editorClass: aSyntaxError editorClass
			text: #contents
			accept: #contents:notifying: 
			readSelection: #contentsSelection
			menu: #paneMenu:shifted:editorClass:)
		frame: (0@0.15 corner: 1@1).

	^ window openInWorldExtent: 380@220! !


!TestRunner methodsFor: 'interface opening' stamp: 'jmv 9/16/2009 11:06'!
buildErrorsList
	^PluggableListMorph
				model: self
				listGetter: #errorsList
				indexGetter: #selectedErrorTest
				indexSetter: #debugErrorTest:.
! !

!TestRunner methodsFor: 'interface opening' stamp: 'jmv 9/16/2009 11:07'!
buildFailuresList
	^PluggableListMorph
				model: self
				listGetter: #failuresList
				indexGetter: #selectedFailureTest
				indexSetter: #debugFailureTest:.
! !

!TestRunner methodsFor: 'interface opening' stamp: 'jmv 9/16/2009 11:18'!
buildTestsList
	| column buttonRow |
	column _ AlignmentMorph proportional.
	testsList _ PluggableListMorphOfMany
				model: self
				listGetter: #tests
				primarySelectionGetter: #selectedSuite
				primarySelectionSetter: #selectedSuite:
				listSelectionGetter: #listSelectionAt:
				listSelectionSetter: #listSelectionAt:put:
				menuGetter: #listMenu:shifted:.
	testsList autoDeselect: false.
	column
		addMorph: testsList
		fullFrame: (LayoutFrame
				fractions: (0 @ 0 corner: 1 @ 0.75)).
	buttonRow _ self optionalButtonRow.
	buttonRow
		color: (Display depth <= 8
				ifTrue: [Color transparent]
				ifFalse: [Color gray alpha: 0.2]).
	buttonRow color: Color transparent.
	column
		addMorph: buttonRow
		fullFrame: (LayoutFrame
				fractions: (0 @ 0.76 corner: 1 @ 1)).
	^ column! !

SimpleHierarchicalListMorph class removeSelector: #on:list:selected:changeSelected:!
SimpleHierarchicalListMorph class removeSelector: #on:list:selected:changeSelected:menu:!
SimpleHierarchicalListMorph class removeSelector: #on:list:selected:changeSelected:menu:keystroke:!
SimpleHierarchicalListMorph removeSelector: #on:list:selected:changeSelected:menu:keystroke:!
PluggableMessageCategoryListMorph class removeSelector: #on:list:selected:changeSelected:menu:keystroke:getRawListSelector:!
PluggableMessageCategoryListMorph removeSelector: #on:list:selected:changeSelected:menu:keystroke:getRawListSelector:!
PluggableListMorphOfMany class removeSelector: #on:list:primarySelection:changePrimarySelection:listSelection:changeListSelection:menu:!
PluggableListMorphOfMany class removeSelector: #on:list:primarySelection:changePrimarySelection:listSelection:changeListSelection:menu:keystroke:!
PluggableListMorphOfMany removeSelector: #on:list:primarySelection:changePrimarySelection:listSelection:changeListSelection:menu:keystroke:!
PluggableListMorph class removeSelector: #on:list:selected:changeSelected:!
PluggableListMorph class removeSelector: #on:list:selected:changeSelected:menu:!
PluggableListMorph class removeSelector: #on:list:selected:changeSelected:menu:keystroke:!
PluggableListMorph removeSelector: #on:list:selected:changeSelected:menu:keystroke:!
"Postscript:
Leave the line above, and replace the rest of this comment by a useful one.
Executable statements should follow this comment, and should
be separated by periods, with no exclamation points (!!).
Be sure to put any further comments in double-quotes, like this one."
Preferences juans!

