-
Notifications
You must be signed in to change notification settings - Fork 560
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove nodes map #506
Remove nodes map #506
Conversation
@@ -490,7 +498,7 @@ | |||
PRODUCT_NAME = "$(TARGET_NAME)"; | |||
PROVISIONING_PROFILE = ""; | |||
PROVISIONING_PROFILE_SPECIFIER = ""; | |||
SWIFT_VERSION = 4.2; | |||
SWIFT_VERSION = 4.0; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Moving back to Swift 4.0?)
@@ -13,27 +13,38 @@ class AnimationUtilsTests: XCTestCase { | |||
|
|||
func testIndex() { | |||
let rootGroup = Group() | |||
let a = Node() | |||
let a = Shape(form: Locus()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What do we create fake Locus here? Locus not an abstract class just because Swift doesn't support it. So it's better to use real form, even for tests.
@@ -22,7 +22,8 @@ enum AnimationType { | |||
|
|||
class BasicAnimation: Animation { | |||
|
|||
var nodeId: String? | |||
weak var node: Node? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we keep only renderer reference? I though we can get node from renderer.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you can create animation when there are no renderers yet. You have to remember something, to later assign renderer to it
|
||
guard let macawView = nodesMap.getView(node) else { | ||
guard let macawView = animation.nodeRenderer?.view as? MacawView else { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we make NodeRenderer.view
a MacawView to avoid casting?
No description provided.