File tree Expand file tree Collapse file tree
TOPasscodeViewController/Views Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -275,13 +275,13 @@ - (void)setHorizontalLayout:(BOOL)horizontalLayout animated:(BOOL)animated durat
275275 self.horizontalZeroButton .contentAlpha = _horizontalLayout ? 0 .0f : 1 .0f ;
276276
277277 void (^animationBlock)(void ) = ^{
278- self.verticalZeroButton .contentAlpha = _horizontalLayout ? 0 .0f : 1 .0f ;
279- self.horizontalZeroButton .contentAlpha = _horizontalLayout ? 1 .0f : 0 .0f ;
278+ self.verticalZeroButton .contentAlpha = self. horizontalLayout ? 0 .0f : 1 .0f ;
279+ self.horizontalZeroButton .contentAlpha = self. horizontalLayout ? 1 .0f : 0 .0f ;
280280 };
281281
282282 void (^completionBlock)(BOOL ) = ^(BOOL complete) {
283- self.verticalZeroButton .hidden = _horizontalLayout ;
284- self.horizontalZeroButton .hidden = !_horizontalLayout ;
283+ self.verticalZeroButton .hidden = self. horizontalLayout ;
284+ self.horizontalZeroButton .hidden = self. horizontalLayout ;
285285 };
286286
287287 // Don't animate if not needed
Original file line number Diff line number Diff line change @@ -251,9 +251,10 @@ - (void)resetPasscodeAnimated:(BOOL)animated playImpact:(BOOL)impact
251251{
252252 [self setPasscode: nil animated: animated];
253253
254- if (impact) {
254+ // Play a negative impact effect
255+ if (@available (iOS 9.0 , *)) {
255256 // https://stackoverflow.com/questions/41444274/how-to-check-if-haptic-engine-uifeedbackgenerator-is-supported
256- AudioServicesPlaySystemSoundWithCompletion (1521 , nil );
257+ if (impact) { AudioServicesPlaySystemSoundWithCompletion (1521 , nil ); }
257258 }
258259
259260 if (!animated) { return ; }
You can’t perform that action at this time.
0 commit comments