The Trunk: HelpSystem-Core-ct.120.mcz

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

The Trunk: HelpSystem-Core-ct.120.mcz

commits-2
Marcel Taeumel uploaded a new version of HelpSystem-Core to project The Trunk:
http://source.squeak.org/trunk/HelpSystem-Core-ct.120.mcz

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

Name: HelpSystem-Core-ct.120
Author: ct
Time: 3 October 2019, 1:39:46.913682 am
UUID: c9b2afad-2786-1f47-a2f5-8ee6258fe75c
Ancestors: HelpSystem-Core-ct.119

Adds browse entry into the HelpBrowser menu

=============== Diff against HelpSystem-Core-mt.116 ===============

Item was added:
+ ----- Method: ClassAPIHelpTopic>>browseTopic (in category 'tools') -----
+ browseTopic
+
+ ^ self theClass theMetaClass browse!

Item was added:
+ ----- Method: ClassBasedHelpTopic>>browseSubtopic: (in category 'tools') -----
+ browseSubtopic: aTopic
+
+ ^ ToolSet browse: self helpClass theMetaClass selector: aTopic key!

Item was added:
+ ----- Method: ClassBasedHelpTopic>>browseTopic (in category 'tools') -----
+ browseTopic
+
+ ^ self helpClass theMetaClass browse!

Item was added:
+ ----- Method: DirectoryBasedHelpTopic>>browseTopic (in category 'tools') -----
+ browseTopic
+
+ ^ FileList openOn: self directoryEntry asFileDirectory!

Item was added:
+ ----- Method: FileBasedHelpTopic>>browseTopic (in category 'tools') -----
+ browseTopic
+
+ ^ FileList openOn: self fileEntry containingDirectory!

Item was added:
+ ----- Method: HelpBrowser>>browseTopic (in category 'actions') -----
+ browseTopic
+
+ ^ (self currentTopic respondsTo: #browseTopic)
+ ifTrue: [self currentTopic browseTopic]
+ ifFalse: [self currentParentTopic browseSubtopic: self currentTopic]!

Item was changed:
  ----- Method: HelpBrowser>>buildTreeWith: (in category 'toolbuilder') -----
  buildTreeWith: builder
 
  ^ builder pluggableTreeSpec new
  model: self;
  nodeClass: HelpTopicListItemWrapper;
  roots: #toplevelTopics;
+ menu: #treeMenu:;
+ keyPress: #treeKey:from:event:;
  getSelected: #currentTopic;
  setSelected: #currentTopic:;
  getSelectedPath: #currentTopicPath;
  setSelectedParent: #currentParentTopic:;
  autoDeselect: false;
  frame: (LayoutFrame
  fractions: (0@0 corner: 0.3@1)
  offsets: (0@ (Preferences standardDefaultTextFont height * 2) corner: 0@0));
  yourself!

Item was added:
+ ----- Method: HelpBrowser>>canBrowseTopic (in category 'testing') -----
+ canBrowseTopic
+
+ ^ (self currentTopic respondsTo: #browseTopic)
+ or: [self currentParentTopic respondsTo: #browseSubtopic:]!

Item was added:
+ ----- Method: HelpBrowser>>exploreTopic (in category 'actions') -----
+ exploreTopic
+
+ ^ self currentTopic explore!

Item was added:
+ ----- Method: HelpBrowser>>inspectTopic (in category 'actions') -----
+ inspectTopic
+
+ ^ self currentTopic inspect!

Item was added:
+ ----- Method: HelpBrowser>>treeKey:from:event: (in category 'menus') -----
+ treeKey: aChar from: aView event: anEvent
+
+ anEvent anyModifierKeyPressed ifFalse: [^ false].
+ aChar
+ caseOf: {
+ [$b] -> [self browseTopic].
+ [$i] -> [self inspectTopic].
+ [$I] -> [self exploreTopic]. }
+ otherwise: [^ false].
+ ^ true!

Item was added:
+ ----- Method: HelpBrowser>>treeListMenu: (in category 'menus') -----
+ treeListMenu: aMenu
+ <treeListMenu>
+
+ self currentTopic ifNil: [^ aMenu].
+
+ aMenu
+ add: 'Inspect (i)' action: #inspectTopic;
+ add: 'Explore (I)' action: #exploreTopic.
+
+ self canBrowseTopic ifTrue: [
+ aMenu
+ addLine;
+ add: 'Browse (b)' action: #browseTopic].
+
+ ^ aMenu!

Item was added:
+ ----- Method: HelpBrowser>>treeMenu: (in category 'menus') -----
+ treeMenu: aMenu
+
+ ^ self menu: aMenu for: #(treeListMenu)!

Item was added:
+ ----- Method: MethodListHelpTopic>>browseTopic (in category 'tools') -----
+ browseTopic
+
+ ^ self theClass browse!

Item was added:
+ ----- Method: PackageAPIHelpTopic>>browseTopic (in category 'tools') -----
+ browseTopic
+
+ ^ (PackageInfo named: packageName) browse!