ios - Touches not recognized after custom transition -


i have issue custom transitions on ipad. create custom transition animates correctly , seems work (i.e. transition occurs). however, when arrive @ destination view controller (after executing isloggedin block), destination view controller unresponsive (it doesn't respond touch events). ii have feeling has call [container insertsubview:toviewcontroller.view belowsubview:fromviewcontroller.view]; because if call [container insertsubview:toviewcontroller.view abovesubview:fromviewcontroller.view]; touches work expected (but cannot see animation, happens on source view controller).

any idea why touch events aren't being recognized?

-(void)animatetransition:(id<uiviewcontrollercontexttransitioning>)transitioncontext { uiviewcontroller *fromviewcontroller = [transitioncontext viewcontrollerforkey:uitransitioncontextfromviewcontrollerkey]; uiviewcontroller *toviewcontroller = [transitioncontext viewcontrollerforkey:uitransitioncontexttoviewcontrollerkey]; uiview *container = [transitioncontext containerview];  //prepare view if (self.isloggedin) {     //insert main view under login view     cgrect frame = cgrectmake(0, 0, toviewcontroller.view.frame.size.height,                               toviewcontroller.view.frame.size.width);     toviewcontroller.view.frame = frame;     [container insertsubview:toviewcontroller.view belowsubview:fromviewcontroller.view]; } else {     cgrect frame = cgrectmake(0, 0, toviewcontroller.view.frame.size.height,                               toviewcontroller.view.frame.size.width);     toviewcontroller.view.frame = frame;     if([toviewcontroller respondstoselector:@selector(openwalls)]) {         [(djvloginviewcontroller*)toviewcontroller openwalls];     }     if([toviewcontroller respondstoselector:@selector(toggleloginviewsalpha:)]) {         [(djvloginviewcontroller*)toviewcontroller toggleloginviewsalpha:0];     }     //insert login view above main view     [container insertsubview:toviewcontroller.view abovesubview:fromviewcontroller.view]; }  //make animations  [uiview animatewithduration:[self transitionduration:transitioncontext]                  animations:^{                      if (self.isloggedin) {                          //perform animation                      } else {                          //perform animation                      }                  } completion:^(bool finished) {                      [transitioncontext completetransition:yes];                  }]; } 

try remove fromview superview:

[uiview animatewithduration:[self transitionduration:transitioncontext]                  animations:^{                      if (self.isloggedin) {                          //perform animation                      } else {                          //perform animation                      }                  } completion:^(bool finished) {                      [fromviewcontroller.view removefromsuperview];                      [transitioncontext completetransition:yes];                  }]; } 

Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -