Preliminar support for notebooks with proper

%metadata nodes to be subscribed into the main help menu.
This commit is contained in:
Offray Vladimir Luna Cárdenas 2017-11-21 19:05:35 +00:00
parent 8f509a0133
commit c18bf5aa06

View File

@ -139,6 +139,20 @@ GrafoscopioDocumentation >> openNotebookAt: index [
ifFalse: [ self updateUI ]] ifFalse: [ self updateUI ]]
] ]
{ #category : #updating }
GrafoscopioDocumentation >> registerIntoDockingBar [
"I detect if any of the documents that are part of my collection contains any metadata
indicating if they should be registered in the main docking bar, and in such case, I add them."
self documents
do: [ :doc | | metadata currentNotebook |
currentNotebook := GrafoscopioNotebook new loadFromFile: self localPlace / doc.
metadata := currentNotebook metadata.
metadata ifNotNil: [
metadata
at: 'showOnHelp'
ifPresent: [ GrafoscopioDockingBar addToHelpMenu: currentNotebook ] ] ]
]
{ #category : #accessing } { #category : #accessing }
GrafoscopioDocumentation >> repository [ GrafoscopioDocumentation >> repository [
^ repository ^ repository