-
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.
Merge pull request #27 from OpenSmock/dev-pla
Create layer event to request repaint in case of internal layer stuff…
- Loading branch information
Showing
9 changed files
with
194 additions
and
46 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Class { | ||
#name : #GeoViewLayerRepaintRequest, | ||
#superclass : #GeoViewLayerEvent, | ||
#category : #'GeoView-Bloc-Events' | ||
} |
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,16 @@ | ||
" | ||
A GeoView2DProjectionTest is a test class for testing the behavior of GeoView2DProjection | ||
" | ||
Class { | ||
#name : #GeoView2DProjectionTest, | ||
#superclass : #TestCase, | ||
#category : #'GeoView-Tests-Projection' | ||
} | ||
|
||
{ #category : #tests } | ||
GeoView2DProjectionTest >> testInitialize [ | ||
|
||
| projection | | ||
projection := GeoView2DProjection new. | ||
self assert: projection cartesianCenter equals: CartesianCoordinates zero. | ||
] |
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,34 @@ | ||
Class { | ||
#name : #DSegmentGeoViewProcessData, | ||
#superclass : #DLeafShapeGeoViewProcessData, | ||
#category : #'GeoView-GShape-ProcessData' | ||
} | ||
|
||
{ #category : #private } | ||
DSegmentGeoViewProcessData >> createGShape2D [ | ||
|
||
^ SmockGSSegment2D new | ||
] | ||
|
||
{ #category : #processing } | ||
DSegmentGeoViewProcessData >> processUpdatedData: aKey incoming: aDSegment with: aGSegment2D context: aContext [ | ||
|
||
| from to | | ||
super processUpdatedData: aKey incoming: aDSegment with: aGSegment2D context: aContext. | ||
(aDSegment coordinates isNil or:[ aDSegment coordinates2 isNil]) ifTrue:[ ^ aGSegment2D ]. | ||
|
||
aDSegment isDrawModeDevice ifTrue:[ | ||
from := aDSegment coordinates. | ||
to := aDSegment coordinates2. | ||
] ifFalse: [ | ||
( aDSegment isDrawModeUser or:[ aDSegment isDrawModeUserProjected ] ) ifTrue:[ | ||
from := self processor projection projCartToPixel: aDSegment coordinates. | ||
to := self processor projection projCartToPixel: aDSegment coordinates2. | ||
]. | ||
]. | ||
|
||
aGSegment2D position: from. | ||
aGSegment2D extent: to. | ||
|
||
^ aGSegment2D | ||
] |
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