Redoing Markdeep export/preview buttons to complain with new GUI conventions.
This commit is contained in:
parent
c38945da71
commit
415c3f0b66
@ -226,3 +226,25 @@ LePage >> storage [
|
||||
(self optionAt: 'storage') ifNil: [ ^ current ].
|
||||
^ self optionAt: 'storage'
|
||||
]
|
||||
|
||||
{ #category : #'*MiniDocs' }
|
||||
LePage >> uiExportButtonFor: anAction [
|
||||
<lePageAction>
|
||||
^ anAction button
|
||||
tooltip: 'Export Page';
|
||||
icon: BrGlamorousVectorIcons down;
|
||||
action: [:aButton | aButton phlow spawnObject: self page asMarkdeepFile ]
|
||||
]
|
||||
|
||||
{ #category : #'*MiniDocs' }
|
||||
LePage >> uiRefrepshWebPreviewButtonFor: anAction [
|
||||
<lePageAction>
|
||||
^ anAction button
|
||||
tooltip: 'Refresh web view';
|
||||
icon: BrGlamorousVectorIcons refresh;
|
||||
action: [
|
||||
self page asMarkdeep exportAsFileOn: (self page storage / self page markdeepFileName).
|
||||
GoogleChrome openWindowOn: self page localHostAddress.
|
||||
"TODO: If Chrome/Chromium are not installed, I should execute:"
|
||||
"WebBrowser openOn: self page localHostAddress" ]
|
||||
]
|
||||
|
@ -1,32 +0,0 @@
|
||||
Extension { #name : #LePageHeaderBuilder }
|
||||
|
||||
{ #category : #'*MiniDocs' }
|
||||
LePageHeaderBuilder >> addExportPageButton [
|
||||
<leHeaderAction>
|
||||
| newButton |
|
||||
|
||||
newButton := BrButton new
|
||||
aptitude: BrGlamorousButtonWithIconAptitude;
|
||||
label: 'Export Page';
|
||||
icon: BrGlamorousVectorIcons down;
|
||||
action: [ :aButton |
|
||||
aButton phlow spawnObject: self page asMarkdeepFile ].
|
||||
self toolbarElement addItem: newButton.
|
||||
]
|
||||
|
||||
{ #category : #'*MiniDocs' }
|
||||
LePageHeaderBuilder >> addRefreshWebViewButton [
|
||||
<leHeaderAction>
|
||||
| newButton |
|
||||
|
||||
newButton := BrButton new
|
||||
aptitude: BrGlamorousButtonWithIconAptitude;
|
||||
label: 'Refresh web view';
|
||||
icon: BrGlamorousVectorIcons refresh;
|
||||
action: [
|
||||
self page asMarkdeep exportAsFileOn: (self page storage / self page markdeepFileName).
|
||||
GoogleChrome openWindowOn: self page localHostAddress.
|
||||
"TODO: If Chrome/Chromium are not installed, I should execute:"
|
||||
"WebBrowser openOn: self page localHostAddress" ].
|
||||
self toolbarElement addItem: newButton.
|
||||
]
|
Loading…
Reference in New Issue
Block a user