• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
[Solved] (iOS) strange animation bug
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Solved] (iOS) strange animation bug


  • Subject: [Solved] (iOS) strange animation bug
  • From: WT <email@hidden>
  • Date: Sat, 02 Jul 2011 18:39:36 +0100

Duh...

I set the button alphas to 0 before animating them back. I can't believe I looked at those lines of code so many times and didn't realize what the problem was. Simply removing those 3 lines makes the code work as intended.

Sorry about the noise.
WT

- (void) showNotesView: (BOOL) show animated: (BOOL) animated;
{
  notesVisible = show;

  self.view.userInteractionEnabled = NO;

  self.btn3.alpha = 0.0f;   // These 3 lines are fine (but not needed) when
  self.btn1.alpha = 0.0f;   // show == YES but cause the problem I was seeing
  self.btn0.alpha = 0.0f;   // when show == NO

  self.btn3.enabled = NO;

  if (! animated)
  {
      [self showNotesView: show];
      self.view.userInteractionEnabled = YES;
  }
  else
  {
      [UIView animateWithDuration: 3.0f
                       animations:
                       ^(void)
                       { [self showNotesView: show]; }
                       completion:
                       ^(BOOL finished)
                       { self.view.userInteractionEnabled = YES; }
       ];
  }
}
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Prev by Date: (iOS) strange animation bug
  • Next by Date: Re: -[NSManagedObjectContext save:] takes 30 minutes, then crashes out of memory
  • Previous by thread: (iOS) strange animation bug
  • Next by thread: Dispatch queues and autorelease pools
  • Index(es):
    • Date
    • Thread