diff --git a/TLYShyNavBar/TLYShyNavBarManager.h b/TLYShyNavBar/TLYShyNavBarManager.h index 0e507dc..b4a0863 100644 --- a/TLYShyNavBar/TLYShyNavBarManager.h +++ b/TLYShyNavBar/TLYShyNavBarManager.h @@ -76,6 +76,11 @@ */ @property (nonatomic) BOOL disable; +/* Set NO to disable shyNavBar snap behavior + * Defaults to YES + */ +@property (nonatomic) BOOL snap; + /* Use this to be notified about contraction and expansion events. */ @property (nonatomic, weak) id delegate; diff --git a/TLYShyNavBar/TLYShyNavBarManager.m b/TLYShyNavBar/TLYShyNavBarManager.m index 63f3267..0ce3c1e 100644 --- a/TLYShyNavBar/TLYShyNavBarManager.m +++ b/TLYShyNavBar/TLYShyNavBarManager.m @@ -58,6 +58,7 @@ - (instancetype)init self.delegateProxy = [[TLYDelegateProxy alloc] initWithMiddleMan:self]; /* Initialize defaults */ + self.snap = YES; self.contracting = NO; self.previousContractionState = YES; @@ -359,7 +360,9 @@ - (void)_handleScrollingEnded }; self.resistanceConsumed = 0; - [self.navBarController snap:self.contracting completion:completion]; + if (_snap) { + [self.navBarController snap:self.contracting completion:completion]; + } } #pragma mark - KVO