Created
January 10, 2015 00:35
-
-
Save chrene/0fbeb4ec9d4f244d43ce to your computer and use it in GitHub Desktop.
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
func initialize() { | |
self.layer.actions = [ | |
"onOrderOut": NSNull(), | |
"sublayers": NSNull(), | |
"contents": NSNull(), | |
"bounds": NSNull() | |
] | |
} | |
func changed() { | |
CATransaction.begin() | |
CATransaction.setDisableActions(true) | |
self.textLayer.string = "a" | |
self.textLayer.frame = self.layer.bounds | |
CATransaction.commit() | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment