Skip to content

Commit

Permalink
fixed workbench closing
Browse files Browse the repository at this point in the history
  • Loading branch information
JanBliznicenko committed Nov 10, 2024
1 parent eb0c530 commit 62f2069
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 5 deletions.
15 changes: 13 additions & 2 deletions repository/OpenPonk-Spec/OPDynamicFormMagritteVisitor.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,17 @@ OPDynamicFormMagritteVisitor >> visitStringDescription: aStringDescription [
{ #category : 'visiting' }
OPDynamicFormMagritteVisitor >> visitToManyRelationDescription: aMAToManyRelationDescription [

form addHeadingLabel: aMAToManyRelationDescription label.
(form addButton: 'Edit ') action: [ controller maEdit ]
| label hasDisplay |
label := aMAToManyRelationDescription label.
form addHeadingLabel: label.
hasDisplay := aMAToManyRelationDescription displayBlockOrSymbol
~=
aMAToManyRelationDescription class
defaultDisplayProperty.
hasDisplay ifTrue: [
(aMAToManyRelationDescription accessor read: controller) do: [ :each |
form addLabel:
(aMAToManyRelationDescription displayStringFor: each) ] ].
(form addButton: 'Edit ' , (label ifNil: [ '' ])) action: [
controller maEdit ]
]
2 changes: 1 addition & 1 deletion repository/OpenPonk-Spec/OPLegacyProjectLoadTest.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ OPLegacyProjectLoadTest >> projectZip [
OPLegacyProjectLoadTest >> tearDown [

self file ensureDelete.
workbench ifNotNil: [ workbench delete ].
workbench ifNotNil: [ workbench close ].
super tearDown
]

Expand Down
2 changes: 1 addition & 1 deletion repository/OpenPonk-Spec/OPProjectBrowser.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ OPProjectBrowser >> openProject: project [

project saveInImage.
project open.
self delete
self withWindowDo: [ :window | window close ]
]

{ #category : 'accessing - spec' }
Expand Down
3 changes: 2 additions & 1 deletion repository/OpenPonk-Spec/OPProjectExitCommand.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,6 @@ OPProjectExitCommand >> defaultMenuItemName [

{ #category : 'accessing' }
OPProjectExitCommand >> execute [
workbench delete

workbench close
]
6 changes: 6 additions & 0 deletions repository/OpenPonk-Spec/OPWorkbench.class.st
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,12 @@ OPWorkbench class >> settingsOn: aBuilder [
(aBuilder group: #openponk) label: 'OpenPonk'
]

{ #category : 'initialize-release' }
OPWorkbench >> close [

self withWindowDo: [ :window | window close ]
]

{ #category : 'opening' }
OPWorkbench >> closeEditorOfDiagram: aDiagram [

Expand Down

0 comments on commit 62f2069

Please sign in to comment.