From bfcbcc6a815411bb75f519a42497eef551ca4ac0 Mon Sep 17 00:00:00 2001 From: arquebuse Date: Wed, 4 Mar 2015 12:22:45 -0800 Subject: [PATCH] Fixed #6 - Publish the animation duration for TGPCamelLabels --- TGPControls/TGPCamelLabels7.h | 1 + TGPControls/TGPCamelLabels7.m | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/TGPControls/TGPCamelLabels7.h b/TGPControls/TGPCamelLabels7.h index 96fbc5f..0e4ee6e 100644 --- a/TGPControls/TGPCamelLabels7.h +++ b/TGPControls/TGPCamelLabels7.h @@ -46,5 +46,6 @@ @property (nonatomic, strong) UIColor * downFontColor; @property (nonatomic, strong) NSArray * names; // Will dictate the number of ticks +@property (nonatomic, assign) NSTimeInterval animationDuration; @end diff --git a/TGPControls/TGPCamelLabels7.m b/TGPControls/TGPCamelLabels7.m index 6ba884e..aa055bd 100644 --- a/TGPControls/TGPCamelLabels7.m +++ b/TGPControls/TGPCamelLabels7.m @@ -60,7 +60,7 @@ - (void)setValue:(NSUInteger)value { _value = value; - [self dockEffect:.15]; + [self dockEffect:self.animationDuration]; } - (void)setUpFontName:(NSString *)upFontName { @@ -154,6 +154,8 @@ _dnLabels = [NSMutableArray array]; _lastValue = NSNotFound; // Never tapped + _animationDuration = 0.15; + [self layoutTrack]; }