-
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.
new ui working correctly without visualization
- Loading branch information
Ingmar Vogel
committed
Jun 19, 2024
1 parent
b2f15b2
commit d2053d6
Showing
52 changed files
with
267 additions
and
232 deletions.
There are no files selected for viewing
9 changes: 6 additions & 3 deletions
9
...ages/Liquid-Network.package/LQLocalObjectRepo.class/instance/at.ifPresent.ifAbsentPut..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,5 +1,8 @@ | ||
accessing | ||
at: key ifPresent: do ifAbsentPut: anObject | ||
|
||
self items at: key ifPresent: [:arg | do value] ifAbsentPut: (STON fromString: (STON toString: anObject)). | ||
at: key ifPresent: do ifAbsentPut: anObject | ||
self items | ||
at: key | ||
ifPresent: [:arg | do value] | ||
ifAbsentPut: (STON | ||
fromString: (STON toString: anObject)). | ||
self changed: #pollList |
7 changes: 4 additions & 3 deletions
7
packages/Liquid-Network.package/LQLocalObjectRepo.class/instance/removeKey..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,5 +1,6 @@ | ||
initialize-release | ||
removeKey: key | ||
|
||
self items removeKey: key ifAbsent: [self error]. | ||
removeKey: key | ||
self items | ||
removeKey: key | ||
ifAbsent: [self error]. | ||
self changed: #pollList |
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
packages/Liquid-UI.package/LQHostMenuNew.class/instance/addVisualization..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,4 +1,4 @@ | ||
accessing | ||
addVisualization: aVisualization | ||
|
||
self visualizations add: aVisualization | ||
addVisualization: aVisualization | ||
self visualizations add: aVisualization | ||
|
15 changes: 7 additions & 8 deletions
15
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildClosePollButtonWith..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,8 @@ | ||
toolbuilder | ||
buildClosePollButtonWith: aBuilder | ||
|
||
^ aBuilder pluggableButtonSpec new | ||
model: self; | ||
label: 'Close Poll'; | ||
help: 'Close poll to prevent participants from handing in answers'; | ||
action: #closePoll; | ||
yourself | ||
buildClosePollButtonWith: aBuilder | ||
^ aBuilder pluggableButtonSpec new model: self; | ||
label: 'Close Poll'; | ||
help: 'Close poll to prevent participants from handing in answers'; | ||
action: #closePoll; | ||
yourself | ||
|
15 changes: 7 additions & 8 deletions
15
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildCreateAnotherPollButton..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,8 @@ | ||
toolbuilder | ||
buildCreateAnotherPollButton: aBuilder | ||
|
||
^ aBuilder pluggableButtonSpec new | ||
model: self; | ||
label: 'Create Another Poll'; | ||
help: 'Creates another poll and opens the draft builder for it in a new window.'; | ||
action: #createPoll; | ||
yourself | ||
buildCreateAnotherPollButton: aBuilder | ||
^ aBuilder pluggableButtonSpec new model: self; | ||
label: 'Create Another Poll'; | ||
help: 'Creates another poll and opens the draft builder for it in a new window.'; | ||
action: #createPoll; | ||
yourself | ||
|
15 changes: 7 additions & 8 deletions
15
...s/Liquid-UI.package/LQHostMenuNew.class/instance/buildCreatePollFromSavedDraftsButton..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,8 @@ | ||
toolbuilder | ||
buildCreatePollFromSavedDraftsButton: aBuilder | ||
|
||
^ aBuilder pluggableButtonSpec new | ||
model: self; | ||
label: 'Create Poll From Saved Drafts'; | ||
help: 'Opens a window with saved drafts you can then edit and run.'; | ||
action: #createPoll; | ||
yourself | ||
buildCreatePollFromSavedDraftsButton: aBuilder | ||
^ aBuilder pluggableButtonSpec new model: self; | ||
label: 'Create Poll From Saved Drafts'; | ||
help: 'Opens a window with saved drafts you can then edit and run.'; | ||
action: #createPoll; | ||
yourself | ||
|
15 changes: 7 additions & 8 deletions
15
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildDeletePollButtonWith..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,8 @@ | ||
toolbuilder | ||
buildDeletePollButtonWith: aBuilder | ||
|
||
^ aBuilder pluggableButtonSpec new | ||
model: self; | ||
label: 'Delete Poll'; | ||
help: 'Delete Poll to clear space for new polls.'; | ||
action: #deletePoll; | ||
yourself | ||
buildDeletePollButtonWith: aBuilder | ||
^ aBuilder pluggableButtonSpec new model: self; | ||
label: 'Delete Poll'; | ||
help: 'Delete Poll to clear space for new polls.'; | ||
action: #deletePoll; | ||
yourself | ||
|
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
15 changes: 7 additions & 8 deletions
15
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildIDTextBoxWith..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,8 @@ | ||
toolbuilder | ||
buildIDTextBoxWith: aBuilder | ||
|
||
^ aBuilder pluggableTextSpec new | ||
model: self; | ||
readOnly: true; | ||
indicateUnacceptedChanges: false; | ||
getText: #pollId; | ||
yourself | ||
buildIDTextBoxWith: aBuilder | ||
^ aBuilder pluggableTextSpec new model: self; | ||
readOnly: true; | ||
indicateUnacceptedChanges: false; | ||
getText: #pollIDString; | ||
yourself | ||
|
13 changes: 6 additions & 7 deletions
13
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildIdCopyButtonWith..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,8 +1,7 @@ | ||
toolbuilder | ||
buildIdCopyButtonWith: aBuilder | ||
|
||
^ aBuilder pluggableButtonSpec new | ||
model: self; | ||
label: 'Copy Poll-ID to Clipboard'; | ||
action: #copyPollId; | ||
yourself | ||
buildIdCopyButtonWith: aBuilder | ||
^ aBuilder pluggableButtonSpec new model: self; | ||
label: 'Copy Poll-ID to Clipboard'; | ||
action: #copyPollId; | ||
yourself | ||
|
16 changes: 7 additions & 9 deletions
16
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildPollListWith..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,10 @@ | ||
toolbuilder | ||
buildPollListWith: aBuilder | ||
|
||
buildPollListWith: aBuilder | ||
| listSpec | | ||
|
||
listSpec := aBuilder pluggableListSpec new. | ||
listSpec | ||
model: self; | ||
list: #pollList; | ||
getIndex: #getIndex; | ||
setIndex: #setIndex:. | ||
^ listSpec | ||
listSpec model: self; | ||
list: #pollList; | ||
getIndex: #getIndex; | ||
setIndex: #setIndex:. | ||
^ listSpec | ||
|
6 changes: 2 additions & 4 deletions
6
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildQuestionBuilder.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,7 +1,5 @@ | ||
toolbuilder | ||
buildQuestionBuilder | ||
|
||
^ {(self questionBuilderAt: self currentQuestion) buildWith: ToolBuilder default} | ||
|
||
|
||
^ {(self questionBuilderAt: self currentQuestion) | ||
buildWith: ToolBuilder default} | ||
|
15 changes: 7 additions & 8 deletions
15
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildStopServerButtonWith..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,8 @@ | ||
toolbuilder | ||
buildStopServerButtonWith: aBuilder | ||
|
||
^ aBuilder pluggableButtonSpec new | ||
model: self; | ||
label: 'Stop Server'; | ||
help: 'Stops the liquid server which allows access to your local polls.'; | ||
action: #stopServer; | ||
yourself | ||
buildStopServerButtonWith: aBuilder | ||
^ aBuilder pluggableButtonSpec new model: self; | ||
label: 'Stop Server'; | ||
help: 'Stops the liquid server which allows access to your local polls.'; | ||
action: #stopServer; | ||
yourself | ||
|
5 changes: 5 additions & 0 deletions
5
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildVisualization.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,5 @@ | ||
toolbuilder | ||
buildVisualization | ||
^ {(self visualizationAt: self currentQuestion) | ||
buildWith: ToolBuilder default} | ||
|
48 changes: 26 additions & 22 deletions
48
packages/Liquid-UI.package/LQHostMenuNew.class/instance/buildWith..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,26 +1,30 @@ | ||
toolbuilder | ||
buildWith: builder | ||
|
||
buildWith: builder | ||
| windowSpec | | ||
|
||
windowSpec := self buildWindowWith: builder specs: { | ||
(self pollListFrame) -> [self buildPollListWith: builder]. | ||
"(self questionBuilderFrame) -> | ||
[builder pluggablePanelSpec new | ||
model: self; | ||
layout: #vertical; | ||
children: #buildQuestionBuilder; | ||
yourself]." | ||
(self idTextBoxFrameFrame) -> [self buildIDTextBoxWith: builder]. | ||
(self deletePollButtonFrame) -> [self buildDeletePollButtonWith: builder]. | ||
(self createPollFromSavedPollsButtonFrame) -> [self buildCreatePollFromSavedDraftsButton: builder]. | ||
(self idCopyButtonFrame) -> [self buildIdCopyButtonWith: builder]. | ||
(self stopServerButtonFrame) -> [self buildStopServerButtonWith: builder]. | ||
(self closePollButtonFrame) -> [self buildClosePollButtonWith: builder]. | ||
(self createAnotherPollButtonFrame) -> [self buildCreateAnotherPollButton: builder]. | ||
(self exportResultsButtonFrame) -> [self buildExportResultsButtonWith: builder]. | ||
}. | ||
windowSpec := self buildWindowWith: builder specs: {self pollListFrame | ||
-> [self buildPollListWith: builder]. self idTextBoxFrameFrame | ||
-> ["(self | ||
questionBuilderFrame) | ||
-> | ||
[builder | ||
pluggablePanelSpec | ||
new | ||
model: | ||
self; | ||
layout: | ||
#vertical; | ||
children: | ||
#buildQuestionBuilder; | ||
yourself]. " | ||
self buildIDTextBoxWith: builder]. self deletePollButtonFrame | ||
-> [self buildDeletePollButtonWith: builder]. self createPollFromSavedPollsButtonFrame | ||
-> [self buildCreatePollFromSavedDraftsButton: builder]. self idCopyButtonFrame | ||
-> [self buildIdCopyButtonWith: builder]. self stopServerButtonFrame | ||
-> [self buildStopServerButtonWith: builder]. self closePollButtonFrame | ||
-> [self buildClosePollButtonWith: builder]. self createAnotherPollButtonFrame | ||
-> [self buildCreateAnotherPollButton: builder]. self exportResultsButtonFrame | ||
-> [self buildExportResultsButtonWith: builder]}. | ||
windowSpec label: 'Liquid - Host'. | ||
^ builder build: windowSpec | ||
|
||
|
||
|
4 changes: 2 additions & 2 deletions
4
packages/Liquid-UI.package/LQHostMenuNew.class/instance/clipboardDelay.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,4 +1,4 @@ | ||
accessing | ||
clipboardDelay | ||
|
||
^ 0.1 | ||
^ 0.1 | ||
|
19 changes: 8 additions & 11 deletions
19
packages/Liquid-UI.package/LQHostMenuNew.class/instance/closePoll.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,13 +1,10 @@ | ||
modifying | ||
closePoll | ||
|
||
self currentPoll == 0 ifFalse: [ | ||
(LQRemotePollRepoServer pollRepo at: self currentPollID | ||
ifAbsent: | ||
[^ 'This poll does not exist.']) | ||
closeWithPassword: (LQPasswordManager default | ||
findPasswordFor: self currentPollID | ||
ifAbsent: [^ UIManager default inform: 'You don''t have access to this poll.']). | ||
self changed: #pollId | ||
] | ||
"self dependents first label: 'closed Poll with ID:'." | ||
self currentPoll == 0 | ||
ifFalse: [(LQRemotePollRepoServer pollRepo | ||
at: self currentPollID | ||
ifAbsent: [^ 'This poll does not exist.']) | ||
closeWithPassword: (LQPasswordManager default | ||
findPasswordFor: self currentPollID | ||
ifAbsent: [^ UIManager default inform: 'You don''t have access to this poll.']). | ||
self changed: #pollIDString] |
4 changes: 2 additions & 2 deletions
4
packages/Liquid-UI.package/LQHostMenuNew.class/instance/closePollButtonFrame.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,8 +1,8 @@ | ||
toolbuilder | ||
closePollButtonFrame | ||
|
||
^ self | ||
frame: 0.9 | ||
fromTop: 0.825 | ||
fromLeft: 0.25 | ||
width: 0.50 | ||
width: 0.5 | ||
|
4 changes: 2 additions & 2 deletions
4
packages/Liquid-UI.package/LQHostMenuNew.class/instance/createAnotherPollButtonFrame.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,8 +1,8 @@ | ||
toolbuilder | ||
createAnotherPollButtonFrame | ||
|
||
^ self | ||
frame: 0.9 | ||
fromTop: 0.75 | ||
fromLeft: 0 | ||
width: 0.25 | ||
width: 0.25 | ||
|
4 changes: 2 additions & 2 deletions
4
...ges/Liquid-UI.package/LQHostMenuNew.class/instance/createPollFromSavedPollsButtonFrame.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,8 +1,8 @@ | ||
toolbuilder | ||
createPollFromSavedPollsButtonFrame | ||
|
||
^ self | ||
frame: 1 | ||
fromTop: 0.9 | ||
fromLeft: 0 | ||
width: 0.25 | ||
width: 0.25 | ||
|
6 changes: 3 additions & 3 deletions
6
packages/Liquid-UI.package/LQHostMenuNew.class/instance/currentPoll..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,4 +1,4 @@ | ||
accessing | ||
currentPoll: aNumber | ||
|
||
currentPoll := aNumber | ||
currentPoll: aNumber | ||
currentPoll := aNumber | ||
|
4 changes: 2 additions & 2 deletions
4
packages/Liquid-UI.package/LQHostMenuNew.class/instance/currentPoll.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,4 +1,4 @@ | ||
accessing | ||
currentPoll | ||
|
||
^ currentPoll | ||
^ currentPoll | ||
|
6 changes: 2 additions & 4 deletions
6
packages/Liquid-UI.package/LQHostMenuNew.class/instance/currentPollID.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,6 +1,4 @@ | ||
accessing | ||
currentPollID | ||
self pollList size == 0 | ||
ifFalse: [^ (self pollList at: self getIndex) id]. | ||
|
||
^ 'No polls in your repo.' | ||
self currentPoll = 0 | ||
ifFalse: [^ (self pollList at: self getIndex) id] |
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
Oops, something went wrong.