generated from hpi-swa-teaching/SWT-Demo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor Lanes to Columns (tests not included)
- Loading branch information
tk
committed
Jul 30, 2022
1 parent
2f1ab20
commit 2f4556e
Showing
248 changed files
with
674 additions
and
682 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
accessing | ||
lastProject: anObject | ||
LastProject := anObject | ||
|
||
LastProject := anObject. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
accessing | ||
lastProject | ||
^ LastProject | ||
|
||
^ LastProject. |
12 changes: 6 additions & 6 deletions
12
...ackage/SPBBoard.class/instance/addLane.st → ...kage/SPBBoard.class/instance/addColumn.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
toolbuilder | ||
addLane | ||
addColumn | ||
|
||
| lane prompt | | ||
| column prompt | | ||
prompt := FillInTheBlankMorph request: 'Enter a lane name' initialAnswer:''. | ||
(prompt = '') | ||
ifTrue: [^ self]. | ||
lane := self boardProvider createColumn: prompt. | ||
column := self boardProvider createColumn: prompt. | ||
|
||
lane | ||
column | ||
board: self; | ||
boardProvider: self boardProvider; | ||
changeProvider: self changeProvider. | ||
self lanes add: lane. | ||
self updateLanesWithCards. | ||
self columns add: column. | ||
self updateColumnsWithCards. |
7 changes: 7 additions & 0 deletions
7
Squello-Core.package/SPBBoard.class/instance/buildAddColumnButtonPanelSpecWith..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
toolbuilder | ||
buildAddColumnButtonPanelSpecWith: aBuilder | ||
|
||
^ aBuilder pluggablePanelSpec new | ||
minimumExtent: (300@200); | ||
children: {self buildAddColumnButtonSpecWith: aBuilder}; | ||
yourself. |
10 changes: 10 additions & 0 deletions
10
Squello-Core.package/SPBBoard.class/instance/buildAddColumnButtonSpecWith..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
toolbuilder | ||
buildAddColumnButtonSpecWith: aBuilder | ||
|
||
^ aBuilder pluggableActionButtonSpec new | ||
frame: (0@0 corner: 1@0.1); | ||
model: self; | ||
action: #addColumn; | ||
label: '+ Add column'; | ||
help: 'add a new column to the board'; | ||
yourself. |
7 changes: 0 additions & 7 deletions
7
Squello-Core.package/SPBBoard.class/instance/buildAddLaneButtonPanelSpecWith..st
This file was deleted.
Oops, something went wrong.
10 changes: 0 additions & 10 deletions
10
Squello-Core.package/SPBBoard.class/instance/buildAddLaneButtonSpecWith..st
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
Squello-Core.package/SPBBoard.class/instance/buildColumnAreaChildren.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
toolbuilder | ||
buildColumnAreaChildren | ||
|
||
| children | | ||
|
||
children := ((self buildColumnsSpecWith: self usedBuilder) | ||
collect: [:spec | self usedBuilder build: spec]) asOrderedCollection. | ||
children | ||
add: ((self usedBuilder build: (self buildAddColumnButtonPanelSpecWith: self usedBuilder)) color: Color lightGray). | ||
|
||
^ children. |
4 changes: 4 additions & 0 deletions
4
Squello-Core.package/SPBBoard.class/instance/buildColumnAreaSpecWith..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
toolbuilder | ||
buildColumnAreaSpecWith: aBuilder | ||
|
||
^ self buildColumnAreaSpecWith: aBuilder width: 0.75. |
6 changes: 3 additions & 3 deletions
6
.../instance/buildLaneAreaSpecWith.width..st → ...nstance/buildColumnAreaSpecWith.width..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
toolbuilder | ||
buildLaneAreaSpecWith: aBuilder width: aNumber | ||
buildColumnAreaSpecWith: aBuilder width: aNumber | ||
|
||
^ aBuilder resizeScrollPaneSpec new | ||
frame: (0@0 corner: aNumber@1); | ||
name: #laneArea; | ||
name: #columnArea; | ||
model: self; | ||
scrollBarThickness: 20; | ||
vScrollBarPolicy: #never; | ||
children: #buildLaneAreaChildren; | ||
children: #buildColumnAreaChildren; | ||
layout: #horizontal; | ||
yourself. |
10 changes: 5 additions & 5 deletions
10
...ss/instance/buildLaneBodySpecWith.and..st → .../instance/buildColumnBodySpecWith.and..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
...ldLaneHeaderAddCardButtonSpecWith.and..st → ...ColumnHeaderAddCardButtonSpecWith.and..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
toolbuilder | ||
buildLaneHeaderAddCardButtonSpecWith: aBuilder and: anSPBLane | ||
buildColumnHeaderAddCardButtonSpecWith: aBuilder and: anSPBColumn | ||
|
||
^ aBuilder pluggableActionButtonSpec new | ||
frame: (0@0.6 corner: 0.85@1); | ||
model: anSPBLane; | ||
model: anSPBColumn; | ||
action: #addCard; | ||
label: '+ Add card'; | ||
help: 'add a new card to the lane'; | ||
help: 'add a new card to the column'; | ||
yourself. |
10 changes: 10 additions & 0 deletions
10
...lo-Core.package/SPBBoard.class/instance/buildColumnHeaderMoveColumnButtonSpecWith.and..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
toolbuilder | ||
buildColumnHeaderMoveColumnButtonSpecWith: aBuilder and: anSPBColumn | ||
|
||
^ aBuilder pluggableActionButtonSpec new | ||
frame: (0.85@0.6 corner: 1@1); | ||
model: anSPBColumn; | ||
action: #moveColumn; | ||
label: '<->'; | ||
help: 'move the column to another place'; | ||
yourself. |
9 changes: 9 additions & 0 deletions
9
Squello-Core.package/SPBBoard.class/instance/buildColumnHeaderSpecWith.and..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
toolbuilder | ||
buildColumnHeaderSpecWith: aBuilder and: anSPBColumn | ||
|
||
^ aBuilder pluggablePanelSpec new | ||
frame: (0@0 corner: 1@0.15); | ||
children: {self buildColumnHeaderTitleSpecWith: aBuilder and: anSPBColumn. | ||
self buildColumnHeaderAddCardButtonSpecWith: aBuilder and: anSPBColumn. | ||
self buildColumnHeaderMoveColumnButtonSpecWith: aBuilder and: anSPBColumn}; | ||
yourself. |
4 changes: 2 additions & 2 deletions
4
...ance/buildLaneHeaderTitleSpecWith.and..st → ...ce/buildColumnHeaderTitleSpecWith.and..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
toolbuilder | ||
buildLaneHeaderTitleSpecWith: aBuilder and: anSPBLane | ||
buildColumnHeaderTitleSpecWith: aBuilder and: anSPBColumn | ||
|
||
^ aBuilder pluggableTextSpec new | ||
frame: (0@0 corner: 1@0.6); | ||
model: anSPBLane; | ||
model: anSPBColumn; | ||
getText: #title; | ||
setText: #updateTitle:; | ||
yourself. |
9 changes: 9 additions & 0 deletions
9
Squello-Core.package/SPBBoard.class/instance/buildColumnSpecWith.and..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
toolbuilder | ||
buildColumnSpecWith: aBuilder and: anSPBColumn | ||
|
||
^ aBuilder pluggablePanelSpec new | ||
minimumExtent: (300@600); | ||
children: {self buildColumnHeaderSpecWith: aBuilder and: anSPBColumn. | ||
self buildColumnBodySpecWith: aBuilder and: anSPBColumn}; | ||
name: ('column', anSPBColumn id asString) asSymbol; | ||
yourself. |
4 changes: 4 additions & 0 deletions
4
Squello-Core.package/SPBBoard.class/instance/buildColumnsSpecWith..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
toolbuilder | ||
buildColumnsSpecWith: aBuilder | ||
|
||
^ self columns collect: [:each | self buildColumnSpecWith: aBuilder and: each]. |
11 changes: 0 additions & 11 deletions
11
Squello-Core.package/SPBBoard.class/instance/buildLaneAreaChildren.st
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
Squello-Core.package/SPBBoard.class/instance/buildLaneAreaSpecWith..st
This file was deleted.
Oops, something went wrong.
10 changes: 0 additions & 10 deletions
10
Squello-Core.package/SPBBoard.class/instance/buildLaneHeaderMoveLaneButtonSpecWith.and..st
This file was deleted.
Oops, something went wrong.
9 changes: 0 additions & 9 deletions
9
Squello-Core.package/SPBBoard.class/instance/buildLaneHeaderSpecWith.and..st
This file was deleted.
Oops, something went wrong.
9 changes: 0 additions & 9 deletions
9
Squello-Core.package/SPBBoard.class/instance/buildLaneSpecWith.and..st
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
Squello-Core.package/SPBBoard.class/instance/buildLanesSpecWith..st
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
accessing | ||
columns: anOrderedCollection | ||
|
||
columns := anOrderedCollection. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
accessing | ||
columns | ||
|
||
^ columns. |
6 changes: 6 additions & 0 deletions
6
Squello-Core.package/SPBBoard.class/instance/createColumns.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
toolbuilder | ||
createColumns | ||
|
||
self columns: self boardProvider queryColumns. | ||
(self columns) | ||
do: [:column | column changeProvider: self changeProvider]. |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
7 changes: 7 additions & 0 deletions
7
Squello-Core.package/SPBBoard.class/instance/rerenderColumns.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
drag and drop | ||
rerenderColumns | ||
|
||
self columns | ||
do: [:column | column pasteup: (self usedBuilder widgetAt: column id). | ||
column rerenderCards. | ||
column board: self]. |
7 changes: 0 additions & 7 deletions
7
Squello-Core.package/SPBBoard.class/instance/rerenderLanes.st
This file was deleted.
Oops, something went wrong.
13 changes: 13 additions & 0 deletions
13
Squello-Core.package/SPBBoard.class/instance/resizeColumnArea.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
update sidebar | ||
resizeColumnArea | ||
|
||
| widgetName columnArea newMinHeight | | ||
columnArea := self usedBuilder widgetAt: #columnArea. | ||
newMinHeight := columnArea height - columnArea scrollBarThickness - 1. | ||
|
||
self columns | ||
do: [:column | widgetName := ('column', column id asString) asSymbol. | ||
(self usedBuilder widgetAt: widgetName) minimumHeight: newMinHeight. | ||
column minimumHeight: newMinHeight * 0.85. | ||
column resizeBottomDetection. | ||
column resizeToFitCards]. |
13 changes: 0 additions & 13 deletions
13
Squello-Core.package/SPBBoard.class/instance/resizeLaneArea.st
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
drag and drop | ||
showColumns | ||
|
||
self columns | ||
do: [:column| column pasteup: (self usedBuilder widgetAt: column id). | ||
column buildCards. | ||
column board: self]. |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.