Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6571209
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T14:51:11+00:00 2026-05-25T14:51:11+00:00

This is strange: I have a view containing a rotated CALayer. The layer is

  • 0

This is strange:

I have a view containing a rotated CALayer. The layer is rotated using a CABasicAnimation on the transform.rotation.z keypath. Works fine.

Then the view including that layer becomes deallocated, and some time later I load everything again. I re-create the view and the rotated layer, and apply that CABasicAnimation. In some situations the animation just won’t start.

So what I do next is this: Performing a delayed selector to kick the animation, should it be stalled. But since kicking it while it is already running causes a noticeable hitch on the screen, I check if the animation object exists:

CABasicAnimation *anim = [rotatedLayer animationForKey:@"transform.rotation.z"];
if (!anim) {
    [self startRotating];
}

Unfortunately, when the animation is not taking place, I do have a CABasicAnimation object applied. Logically, because I created it. The animation just won’t start. However, when I then go ahead and apply it once again after one second or so, then it works.

I even get the animiationDidStart message from the delegate:

- (void)animationDidStart:(CAAnimation *)theAnimation {
    NSLog(@"animation started!!!!");
}

There’s a good chance that this is not a bug but a feature.

Is there a way to give that CABasicAnimation object a kick to make it run, even if CoreAnimation thinks that it is running already (which is not the case sometimes), without giving it a kick in the butt when it actually really was running already?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T14:51:11+00:00Added an answer on May 25, 2026 at 2:51 pm

    Go through the pause and resume of animation as given in Apple’s Technical Q&A

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This one is strange...I have the following markup for a view using Razor view
I have this strange issue with my web app. You see, I'm using jQuery
I have a strange situation in one view controller where this line crashes in
I have this strange call stack and I am stumped to understand why. It
Why this two functions have the strange behaviour of when I click on thead,
This is a strange one... In a windows forms app (VB.NET/VS 2005) I have
This a bit of strange one.... We have an internal web app that runs
I have the following query, now the strange thing is if I run this
i am having a strange problem, i have a static class like this public
it is very strange, because this error doesn't happen all the time... I have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.