move a CALayer (add animation)

well I have a CALayer layer and I would like to move it, with a CADisplaylink. Like : + 10, + 10);

but I can't use center or position for the layer.Here is my problem, I want to make it move like it was a uiimageview.


To move layer try to use this method

-(void)moveLayer:(CALayer*)layer to:(CGPoint)point{
    CABasicAnimation *animation = [CABasicAnimation animationWithKeyPath:@"position"];
    animation.fromValue = [layer valueForKey:@"position"];
    animation.toValue = [NSValue valueWithCGPoint:point];
    layer.position = point;
    [layer addAnimation:animation forKey:@"position"];

Need Your Help

GNU screen custom key bindings format

key-bindings gnu-screen screenrc

I am trying to add key bindings to the .screenrc file for making a lot of things easier. So far I have understood the following pattern

Strategy to create multiple representations for the same class based on criteria using ROAR gem?

ruby-on-rails json rails-roar representable

This is actually a best practices / usage question on hwo to use Roar & representable in Rails, as I didn't find any examples of that. Here are two scenarios. I use decorator pattern.