The Trunk: ToolBuilder-Morphic-mt.161.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: ToolBuilder-Morphic-mt.161.mcz

commits-2
Marcel Taeumel uploaded a new version of ToolBuilder-Morphic to project The Trunk:
http://source.squeak.org/trunk/ToolBuilder-Morphic-mt.161.mcz

==================== Summary ====================

Name: ToolBuilder-Morphic-mt.161
Author: mt
Time: 5 April 2016, 10:37:14.038517 am
UUID: 43803efe-1ca3-ad42-b319-88df297b1ae6
Ancestors: ToolBuilder-Morphic-mt.160

Use helpItem to get help per item. Use help to get help for the whole widget.

=============== Diff against ToolBuilder-Morphic-mt.160 ===============

Item was changed:
  ----- Method: MorphicToolBuilder>>buildPluggableAlternateMultiSelectionList: (in category 'widgets optional') -----
  buildPluggableAlternateMultiSelectionList: aSpec
  | listMorph listClass |
  aSpec getSelected ifNotNil: [ ^ self error: 'There is no PluggableAlternateListMorphOfManyByItem' ].
  listClass := self alternateMultiSelectListClass.
  listMorph := listClass
  on: aSpec model
  list: aSpec list
  primarySelection: aSpec getIndex
  changePrimarySelection: aSpec setIndex
  listSelection: aSpec getSelectionList
  changeListSelection: aSpec setSelectionList
  menu: aSpec menu.
  listMorph
  setProperty: #highlightSelector toValue: #highlightMessageList:with: ;
  setProperty: #itemConversionMethod toValue: #asStringOrText ;
  setProperty: #balloonTextSelectorForSubMorphs toValue: #balloonTextForClassAndMethodString ;
  enableDragNDrop: SystemBrowser browseWithDragNDrop ;
  menuTitleSelector: #messageListSelectorTitle.
  self
  register: listMorph
  id: aSpec name.
  listMorph
  keystrokeActionSelector: aSpec keyPress ;
  getListElementSelector: aSpec listItem ;
  getListSizeSelector: aSpec listSize;
  getIconSelector: aSpec icon;
+ getHelpSelector: aSpec helpItem.
+
+ self buildHelpFor: listMorph spec: aSpec.
+
- getHelpSelector: aSpec help.
  self
  setFrame: aSpec frame
  in: listMorph.
  self setLayoutHintsFor: listMorph spec: aSpec.
  parent ifNotNil: [ self add: listMorph to: parent ].
  panes ifNotNil: [ aSpec list ifNotNil:[panes add: aSpec list ] ].
  ^ listMorph!

Item was changed:
  ----- Method: MorphicToolBuilder>>buildPluggableList: (in category 'widgets required') -----
  buildPluggableList: aSpec
  | widget listClass getIndex setIndex |
  aSpec getSelected ifNil:[
  listClass := self listClass.
  getIndex := aSpec getIndex.
  setIndex := aSpec setIndex.
  ] ifNotNil:[
  listClass := self listByItemClass.
  getIndex := aSpec getSelected.
  setIndex := aSpec setSelected.
  ].
  widget := listClass on: aSpec model
  list: aSpec list
  selected: getIndex
  changeSelected: setIndex
  menu: aSpec menu
  keystroke: aSpec keyPress.
  self register: widget id: aSpec name.
 
  "Override default scroll bar policies if needed. Widget will use preference values otherwise."
  aSpec hScrollBarPolicy ifNotNil: [:policy |
  policy caseOf: {
  [#always] -> [widget alwaysShowHScrollBar].
  [#never] -> [widget hideHScrollBarIndefinitely].
  [#whenNeeded] -> [widget showHScrollBarOnlyWhenNeeded]. } ].
  aSpec vScrollBarPolicy ifNotNil: [:policy |
  policy caseOf: {
  [#always] -> [widget alwaysShowVScrollBar].
  [#never] -> [widget hideVScrollBarIndefinitely].
  [#whenNeeded] -> [widget showVScrollBarOnlyWhenNeeded]. } ].
 
  widget getListElementSelector: aSpec listItem.
  widget getListSizeSelector: aSpec listSize.
  widget getIconSelector: aSpec icon.
+ widget getHelpSelector: aSpec helpItem.
- widget getHelpSelector: aSpec help.
  widget doubleClickSelector: aSpec doubleClick.
 
  widget dragItemSelector: aSpec dragItem.
  widget dropItemSelector: aSpec dropItem.
  widget wantsDropSelector: aSpec dropAccept.
  widget dragStartedSelector: aSpec dragStarted.
 
  widget autoDeselect: aSpec autoDeselect.
  widget keystrokePreviewSelector: aSpec keystrokePreview.
 
  widget
  borderWidth: 1;
  borderColor: Color lightGray;
  color: (aSpec color
  ifNil: [Color white]
  ifNotNil: [aSpec color]).
+
+ self buildHelpFor: widget spec: aSpec.
 
  self setFrame: aSpec frame in: widget.
  self setLayoutHintsFor: widget spec: aSpec.
 
  parent ifNotNil:[self add: widget to: parent].
  panes ifNotNil:[
  aSpec list ifNotNil:[panes add: aSpec list].
  ].
  ^widget!