UITableView Row Animation IDs?

Discussion in 'iOS Programming' started by Darkroom, Sep 1, 2009.

  1. Darkroom Guest

    Darkroom

    Joined:
    Dec 15, 2006
    Location:
    Montréal, Canada
    #1
    i would like to execute some code after a row is deleted from my table with animation. i've chosen UITableViewRowAnimationRight as the row animation. is there a title constant for this animation that would allow me to use the following method?:

    Code:
    - (void)animationDidStop:(NSString *)animationID finished:(NSNumber *)finished context:(void *)context
    	{
    	if ((animationID == [COLOR="Red"]UITableViewRowAnimationRight[/COLOR]) && finished)
    		//execute code;
    	}
    
    i know this is possible with performSelector:withObject:afterDelay, but that seems a bit dirty. perhaps it's the only way?
     
  2. PhoneyDeveloper macrumors 68030

    PhoneyDeveloper

    Joined:
    Sep 2, 2008
    #2
    Just a guess. Wrap your call to deleteRowsAtIndexPaths: in your own animation block and add the didStopSelector to that animation.
     
  3. dejo Moderator

    dejo

    Staff Member

    Joined:
    Sep 2, 2004
    Location:
    The Centennial State
    #3
    I'm not even sure there is any kind of "animationID". You don't seem to have the parameter types (or even numbers) for animationDidStop: correct. It looks like it should be:
    Code:
    - (void)animationDidStop:(CAAnimation *)theAnimation finished:(BOOL)flag
     

Share This Page