-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
39 changed files
with
171 additions
and
42 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
9 changes: 9 additions & 0 deletions
9
...mationsEditor-Core.package/AnimationsEditorPropertyStartEnd.class/instance/findLastKey.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 @@ | ||
updating | ||
findLastKey | ||
| last | | ||
|
||
last:= self endTime. | ||
self property subproperties do:[:subproperty | subproperty targetValues keysDo: [:key | key > last ifTrue:[last:= key]]]. | ||
^last | ||
|
||
|
3 changes: 3 additions & 0 deletions
3
...nimationsEditor-Core.package/AnimationsEditorPropertyStartEnd.class/instance/property..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,3 @@ | ||
accessing | ||
property: anObject | ||
property := anObject |
3 changes: 3 additions & 0 deletions
3
...AnimationsEditor-Core.package/AnimationsEditorPropertyStartEnd.class/instance/property.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,3 @@ | ||
accessing | ||
property | ||
^ property |
6 changes: 6 additions & 0 deletions
6
.../AnimationsEditor-Core.package/AnimationsEditorPropertyStartEnd.class/instance/update..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 @@ | ||
updating | ||
update: aSymbol | ||
aSymbol = #addKeyframes | ||
ifTrue:[self endTime < self findLastKey ifTrue:[self endTime: self findLastKey]]. | ||
|
||
|
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
17 changes: 7 additions & 10 deletions
17
...mationsEditor-Core.package/AnimationsEditorTimebar.class/instance/addIntermediateLines.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,9 @@ | ||
updating | ||
addIntermediateLines | ||
| positionX intermediateStart intermediateEnd lineRepetition | | ||
|
||
intermediateStart := self timeline startTime + 1. | ||
intermediateEnd := self timeline endTime - 1. | ||
lineRepetition := 100. | ||
intermediateStart to: intermediateEnd | ||
do: [:frame | frame \\ lineRepetition = 0 | ||
ifTrue: [ | ||
positionX := self convertFrameToPosition: frame. | ||
self addLineFrom: positionX @ self height to: positionX @ (self height - self lineHeight)]]. | ||
| positionX frame | | ||
frame := self timeline startTime + self intermediateLineDistance. | ||
[self timeline endTime > frame] | ||
whileTrue: [positionX := self convertFrameToPosition: frame. | ||
self addLineFrom: positionX @ self height to: positionX @ (self height - self lineHeight). | ||
self addLineLabelFor: (frame asString) to: (positionX - self labelXOffset) @ (self height - self lineHeight - self labelYOffset). | ||
frame := frame + self intermediateLineDistance.]. |
9 changes: 9 additions & 0 deletions
9
...imationsEditor-Core.package/AnimationsEditorTimebar.class/instance/addLineLabelFor.to..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 @@ | ||
updating | ||
addLineLabelFor: aFrame to: aPosition | ||
| label | | ||
|
||
label := StringMorph new. | ||
label contents: aFrame. | ||
label position: aPosition. | ||
label fontName: 'default' size: 13. | ||
self addMorph: label. |
3 changes: 3 additions & 0 deletions
3
...onsEditor-Core.package/AnimationsEditorTimebar.class/instance/intermediateLineDistance.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,3 @@ | ||
constants | ||
intermediateLineDistance | ||
^100. |
4 changes: 4 additions & 0 deletions
4
...ages/AnimationsEditor-Core.package/AnimationsEditorTimebar.class/instance/labelXOffset.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 @@ | ||
constants | ||
labelXOffset | ||
|
||
^ 10 |
4 changes: 4 additions & 0 deletions
4
...ages/AnimationsEditor-Core.package/AnimationsEditorTimebar.class/instance/labelYOffset.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 @@ | ||
constants | ||
labelYOffset | ||
|
||
^ 10 |
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
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
4 changes: 2 additions & 2 deletions
4
packages/AnimationsEditor-Core.package/AnimationsEditorTimeline.class/instance/update..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 @@ | ||
updating | ||
update: aStartEndProperty | ||
self updateExtent. | ||
self startTime: aStartEndProperty startTime. | ||
self endTime: aStartEndProperty endTime. | ||
self endTime: aStartEndProperty endTime. | ||
self updateExtent. | ||
self createTracks. | ||
Transcript show: 'update'. | ||
self addTimebar. |
10 changes: 9 additions & 1 deletion
10
...ges/AnimationsEditor-Core.package/AnimationsEditorTimeline.class/instance/updateExtent.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,3 +1,11 @@ | ||
updating | ||
updateExtent | ||
self extent: self scrollPane extent - (self borderWidth * 2). | ||
| normalHeight fullWidth | | ||
|
||
normalHeight := self scrollPane height - self borderWidth. | ||
fullWidth := self endTime + self startMargin + self endMargin. | ||
self width: fullWidth. | ||
fullWidth > self scrollPane width | ||
ifTrue: [self height: normalHeight - self scrollPane scrollBarThickness.] | ||
ifFalse: [self height: normalHeight.]. | ||
|
8 changes: 8 additions & 0 deletions
8
...ionsEditor-Core.package/AnimationsEditorTimeline.class/instance/updateStartEndProperty.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,8 @@ | ||
updating | ||
updateStartEndProperty | ||
| startEndProperty | | ||
|
||
startEndProperty := self animationsEditor propertyStartEnd. | ||
startEndProperty property: self property. "<--- Ich vermute, dass diese Zeile nicht ausgeführt wird und dadurch den Defekt erzeugt." | ||
self property subproperties | ||
do:[:subproperty | subproperty addDependent: startEndProperty]. |
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
8 changes: 1 addition & 7 deletions
8
...tor-Core.package/AnimationsEditorTimelineObject.class/instance/convertFrameToPosition..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,3 @@ | ||
creation | ||
convertFrameToPosition: aFrame | ||
| position totalDuration framesPerPixel frameOffset | | ||
|
||
totalDuration := self timeline endTime - self timeline startTime. | ||
framesPerPixel := totalDuration / self lineSegmentWidth. | ||
frameOffset := aFrame / framesPerPixel. | ||
position := self startMargin + frameOffset. | ||
^ position. | ||
^self startMargin + aFrame. |
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
3 changes: 3 additions & 0 deletions
3
....package/AnimationsEditorPropertyStartEndTest.class/instance/animationsEditorInstance..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,3 @@ | ||
accessing | ||
animationsEditorInstance: anObject | ||
animationsEditorInstance := anObject |
3 changes: 3 additions & 0 deletions
3
...s.package/AnimationsEditorPropertyStartEndTest.class/instance/animationsEditorInstance.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,3 @@ | ||
accessing | ||
animationsEditorInstance | ||
^ animationsEditorInstance |
3 changes: 3 additions & 0 deletions
3
...mationsEditor-Tests.package/AnimationsEditorPropertyStartEndTest.class/instance/morph..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,3 @@ | ||
accessing | ||
morph: anObject | ||
morph := anObject |
3 changes: 3 additions & 0 deletions
3
...imationsEditor-Tests.package/AnimationsEditorPropertyStartEndTest.class/instance/morph.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,3 @@ | ||
accessing | ||
morph | ||
^ morph |
3 changes: 3 additions & 0 deletions
3
...ionsEditor-Tests.package/AnimationsEditorPropertyStartEndTest.class/instance/property..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,3 @@ | ||
accessing | ||
property: anObject | ||
property := anObject |
3 changes: 3 additions & 0 deletions
3
...tionsEditor-Tests.package/AnimationsEditorPropertyStartEndTest.class/instance/property.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,3 @@ | ||
accessing | ||
property | ||
^ property |
6 changes: 5 additions & 1 deletion
6
...imationsEditor-Tests.package/AnimationsEditorPropertyStartEndTest.class/instance/setUp.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,8 @@ | ||
running | ||
setUp | ||
super setUp. | ||
self propertyStartEnd: AnimationsEditorPropertyStartEnd new. | ||
self animationsEditorInstance: AnimationsEditor open. | ||
self propertyStartEnd: self animationsEditorInstance propertyStartEnd. | ||
self morph: Morph new openInWorld. | ||
self animationsEditorInstance addTargetMorph: self morph. | ||
self property: self animationsEditorInstance propertyList second. |
6 changes: 6 additions & 0 deletions
6
...tionsEditor-Tests.package/AnimationsEditorPropertyStartEndTest.class/instance/tearDown.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 @@ | ||
running | ||
tearDown | ||
self morph isFlexed | ||
ifTrue: [self morph owner abandon]. | ||
self morph abandon. | ||
self animationsEditorInstance windowReference abandon. |
18 changes: 18 additions & 0 deletions
18
...ackage/AnimationsEditorPropertyStartEndTest.class/instance/testAddKeyframeAfterEndtime.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,18 @@ | ||
testing | ||
testAddKeyframeAfterEndtime | ||
| positionProperty oldEndtime propertyStartEnd newEndtime| | ||
|
||
positionProperty := self property subproperties at: 'position'. | ||
propertyStartEnd := self animationsEditorInstance propertyStartEnd. | ||
self animationsEditorInstance selectedTreeNode: positionProperty. | ||
oldEndtime := propertyStartEnd endTime. | ||
positionProperty | ||
positionX: 555; | ||
positionY: 555; | ||
frame: oldEndtime + 1; | ||
addKeyframe. | ||
newEndtime := propertyStartEnd endTime. | ||
self assert: oldEndtime + 1 =newEndtime. | ||
|
||
|
||
|
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
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
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
10 changes: 10 additions & 0 deletions
10
...sEditor-Tests.package/AnimationsEditorTimelineTest.class/instance/testHeightOfTimeline.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 @@ | ||
testing | ||
testHeightOfTimeline | ||
| oldHeight scrollBarThickness offScreenFrame | | ||
|
||
offScreenFrame := self animationsEditorInstance mainWindow width. | ||
self animationsEditorInstance propertyStartEnd endTime: 0. | ||
oldHeight := self timeline height. | ||
self createKeyframeWith: self animationPosition on: offScreenFrame. | ||
scrollBarThickness := self timeline scrollPane scrollBarThickness. | ||
self assert: oldHeight - scrollBarThickness = self timeline height. |
7 changes: 7 additions & 0 deletions
7
...nsEditor-Tests.package/AnimationsEditorTimelineTest.class/instance/testWidthOfTimeline.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 @@ | ||
testing | ||
testWidthOfTimeline | ||
| oldWidth | | ||
|
||
oldWidth := self timeline width. | ||
self createKeyframeWith: self animationPosition on: self endFrame + 2000. | ||
self assert: oldWidth + 2000 = self timeline width. |
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