uibutton - iOS Custom Animated Button does not scale back after pushing a page -
My iOS custom animated buttons do not revert back after pushing the page. Is it a way to scale my buttons before too late is? Because when I come back to the original page, I think my button is still small. You can try to scale it to a larger size whenever the button Containing a view is about who appears To see it: Weapper: The controller's method of viewing the button. @interface CustomButton () @property (assign, nonatamic) BOOL is small; @end @implementation Custom Button - (ID) Init With Code: (Encoder *) Decoder {if (Self = [Super Init With Coder: Decoder]) {self.isSmall = NO; } Healthy return; } - (id) initWithFrame: (CGRect) frame {if (self = [super initWithFrame: frame]) {self.isSmall = NO; } Healthy return; } - (zero) touches: (NSSET *) touches the event: (UIEvent *) event {if (!self.ssmlL) {self.isSmall = YES; [Self-scale tasal]; } [Super touching: left with event: incident]; } - Added the (zero) touch: (NSSET *) touches the event: (Uiivent *) event {if (self.ssmll) {self.IMSSLL = no; [Self scale tbbig]; } [Super touchend: Event: touches with event]; } - (Zero) ScaleToSmall {CABasic Animation * Animation = [with CABasic Animation Animation: @ "Transform"]; Anim.timingFunction = [CAMediaTimingFunction functionWithName: kCAMediaTimingFunctionEaseIn]; Anim.duration = 0.100; Anim.repeatCount = 1; Anim.additive = Yes; Anim.removedOnCompletion = No; Anim.fillMode = kCAFillModeForwards; Anim.toValue = [NSValue value withCatransform3D: CATransform3DMakeScale (0.8, 0.8, 1.0)]; [Late Ad Animation: Anime Foreke: Nile]; } - (zero) scale tabbig {CABasic Animation * Animation = [with CABasic Animation Animation: @ "Transform"]; Anim.timingFunction = [CAMediaTimingFunction functionWithName: kCAMediaTimingFunctionEaseOut]; Anim.duration = 0.100; Anim.repeatCount = 1; Anim.additive = Yes; Anim.removedOnCompletion = No; Anim.fillMode = kCAFillModeForwards; Anim.toValue = [NSValue value withCatransform3D: CATransform3DMakeScale (1.25, 1.25, 1.0)]; [Late Ad Animation: Anime Foreke: Nile]; }
Comments
Post a Comment