From 51ab05d08f266224ed16916aa11e6e902415feed Mon Sep 17 00:00:00 2001 From: JanBliznicenko Date: Tue, 1 Aug 2023 11:05:14 +0200 Subject: [PATCH] conforming Roassal3 changes --- .../OpenPonk-BPMN/OPBPMNActivityShape.class.st | 7 +++++-- .../OPBPMNBoundaryEventShape.class.st | 12 ++++++++---- ...PBPMNCollapsedSubProcessController.class.st | 18 +++++++++++------- .../OPBPMNCollapsedSubProcessShape.class.st | 14 ++++++++++---- .../OPBPMNDataObjectShape.class.st | 5 ++++- 5 files changed, 38 insertions(+), 18 deletions(-) diff --git a/repository/OpenPonk-BPMN/OPBPMNActivityShape.class.st b/repository/OpenPonk-BPMN/OPBPMNActivityShape.class.st index 8f80bec..daa7619 100644 --- a/repository/OpenPonk-BPMN/OPBPMNActivityShape.class.st +++ b/repository/OpenPonk-BPMN/OPBPMNActivityShape.class.st @@ -62,10 +62,13 @@ OPBPMNActivityShape >> renderShapeDetails [ RSLocation new stick: icon on: self roassalShape; offset: -28 @ -16. - self roassalShape when: RSShapeRemovedEvent do: [ icon remove ]. + self roassalShape + when: RSShapeRemovedEvent + do: [ icon remove ] + for: self. self color: (Color fromHexString: 'f2f2f2'). -"TODO for what are good bounds?????" + "TODO for what are good bounds?????" self bounds: nil. roassalShape @ OPRSSelectionDraggable. selectable := OPRSSelectable new. diff --git a/repository/OpenPonk-BPMN/OPBPMNBoundaryEventShape.class.st b/repository/OpenPonk-BPMN/OPBPMNBoundaryEventShape.class.st index eae0f80..7957aa0 100644 --- a/repository/OpenPonk-BPMN/OPBPMNBoundaryEventShape.class.st +++ b/repository/OpenPonk-BPMN/OPBPMNBoundaryEventShape.class.st @@ -59,20 +59,24 @@ OPBPMNBoundaryEventShape >> renderShapeDetails [ yourself. self canvas add: icon. RSLocation new stick: icon on: self roassalShape. - self roassalShape when: RSShapeRemovedEvent do: [ icon remove ]. + self roassalShape + when: RSShapeRemovedEvent + do: [ icon remove ] + for: self. innerCircle := RSCircle new size: 31; borderColor: Color black; color: Color transparent; - border: borderIn; + border: borderIn; yourself. self canvas add: innerCircle. RSLocation new stick: innerCircle on: self roassalShape. self roassalShape when: RSShapeRemovedEvent - do: [ innerCircle remove ]. - "TODO for what are good bounds?????" + do: [ innerCircle remove ] + for: self. + "TODO for what are good bounds?????" self bounds: nil. "roassalShape @ OPRSSelectionDraggable." selectable := OPRSSelectable new. diff --git a/repository/OpenPonk-BPMN/OPBPMNCollapsedSubProcessController.class.st b/repository/OpenPonk-BPMN/OPBPMNCollapsedSubProcessController.class.st index 2de6946..f24d217 100644 --- a/repository/OpenPonk-BPMN/OPBPMNCollapsedSubProcessController.class.st +++ b/repository/OpenPonk-BPMN/OPBPMNCollapsedSubProcessController.class.st @@ -11,23 +11,26 @@ Class { { #category : #testing } OPBPMNCollapsedSubProcessController >> buildEditorForm: aForm [ + | anEvent | super buildEditorForm: aForm. (aForm addDroplist: 'Marker') - items: #( #None #MarkerParallel #MarkerSequential #MarkerLoop #MarkerCompensation #MarkerAdhoc); + items: + #( #None #MarkerParallel #MarkerSequential #MarkerLoop #MarkerCompensation + #MarkerAdhoc ); displayIcon: [ :type | self model typeIconFor: type ]; display: [ :type | type asString ]; selectItem: self model type; - whenSelectedItemChangedDo: [ :newValue | + whenSelectedItemChangedDo: [ :newValue | self model type: newValue. self diagramElement modelChanged ]. - (aForm addCheckbox: 'Is Call Activity?') + (aForm addCheckbox: 'Is Call Activity?') state: self model isCallActivity; - whenChangedDo: [ :val | + whenChangedDo: [ :val | self model isCallActivity: val. self diagramElement modelChanged ]. - - (aForm addButton: 'Add Boundary Event') action: [ + + (aForm addButton: 'Add Boundary Event') action: [ anEvent := OPBPMNBoundaryEventController new createModelIn: self model; showInDiagram: self diagramController; @@ -42,7 +45,8 @@ OPBPMNCollapsedSubProcessController >> buildEditorForm: aForm [ offset: -1 @ 22. self diagramElement roassalShape when: RSShapeRemovedEvent - do: [ anEvent diagramElement roassalShape remove ] ]. + do: [ anEvent diagramElement roassalShape remove ] + for: self ]. self diagramElement modelChanged ] diff --git a/repository/OpenPonk-BPMN/OPBPMNCollapsedSubProcessShape.class.st b/repository/OpenPonk-BPMN/OPBPMNCollapsedSubProcessShape.class.st index 91a53ef..0767b5d 100644 --- a/repository/OpenPonk-BPMN/OPBPMNCollapsedSubProcessShape.class.st +++ b/repository/OpenPonk-BPMN/OPBPMNCollapsedSubProcessShape.class.st @@ -56,8 +56,8 @@ OPBPMNCollapsedSubProcessShape >> renderShapeDetails [ label shapeBuilder labelShape color: Color black. roassalShape addInteraction: label. subprocessIcon := RSBitmap new - form: self typeBasicIcon; - yourself. + form: self typeBasicIcon; + yourself. icon := RSBitmap new form: self typeIconForModel; yourself. @@ -66,11 +66,17 @@ OPBPMNCollapsedSubProcessShape >> renderShapeDetails [ RSLocation new stick: icon on: self roassalShape; offset: -16 @ 18. - self roassalShape when: RSShapeRemovedEvent do: [ icon remove ]. + self roassalShape + when: RSShapeRemovedEvent + do: [ icon remove ] + for: self. RSLocation new stick: subprocessIcon on: self roassalShape; offset: 0 @ 18. - self roassalShape when: RSShapeRemovedEvent do: [ subprocessIcon remove ]. + self roassalShape + when: RSShapeRemovedEvent + do: [ subprocessIcon remove ] + for: self. self color: (Color fromHexString: 'f2f2f2'). roassalShape @ OPRSSelectionDraggable. diff --git a/repository/OpenPonk-BPMN/OPBPMNDataObjectShape.class.st b/repository/OpenPonk-BPMN/OPBPMNDataObjectShape.class.st index 219bff3..557415d 100644 --- a/repository/OpenPonk-BPMN/OPBPMNDataObjectShape.class.st +++ b/repository/OpenPonk-BPMN/OPBPMNDataObjectShape.class.st @@ -81,7 +81,10 @@ OPBPMNDataObjectShape >> renderShapeDetails [ yourself. self canvas add: icon. RSLocation new stick: icon on: self roassalShape. - self roassalShape when: RSShapeRemovedEvent do: [ icon remove ]. + self roassalShape + when: RSShapeRemovedEvent + do: [ icon remove ] + for: self. roassalShape @ OPRSSelectionDraggable. selectable := OPRSSelectable new.