Skip to content

Commit

Permalink
Fix bindings in MiPlayground.
Browse files Browse the repository at this point in the history
  • Loading branch information
ClotildeToullec committed Nov 14, 2024
1 parent 5c48916 commit 2292aeb
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 2 deletions.
15 changes: 15 additions & 0 deletions src/MooseIDE-NewTools/MiPlaygroundInteractionModel.class.st
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
"
As my superclass, I am used in playgrounds to access bindings.
I am specific to Moose.
"
Class {
#name : #MiPlaygroundInteractionModel,
#superclass : #StPlaygroundInteractionModel,
#category : #'MooseIDE-NewTools-Playground'
}

{ #category : #'as yet unclassified' }
MiPlaygroundInteractionModel >> application [

^ MiApplication current
]
12 changes: 10 additions & 2 deletions src/MooseIDE-NewTools/MiPlaygroundPagePresenter.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,10 @@ MiPlaygroundPagePresenter >> addMooseToolbarCommandsTo: aGroup [

{ #category : #accessing }
MiPlaygroundPagePresenter >> application [
"This is a hack to avoid opening Pharo system tools in MiApplication"
"This allows the playground to use the StPharoApplication instead of the Moose-specific application.
We do not want the native windows to open silently as Moose windows."

^ StPharoApplication current
^ application
]

{ #category : #'public access' }
Expand All @@ -38,6 +39,13 @@ MiPlaygroundPagePresenter >> evaluate [
onError: [ :e | e pass ]
]

{ #category : #initialization }
MiPlaygroundPagePresenter >> initializePresenters [

super initializePresenters.
text interactionModel: MiPlaygroundInteractionModel new
]

{ #category : #private }
MiPlaygroundPagePresenter >> menuActionsFor: aCodePresenter [

Expand Down

0 comments on commit 2292aeb

Please sign in to comment.