Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added coding and decoding of continuous and wrapAround values, take 2

  • Loading branch information...
commit 7345f8ffa8c2dc141df24230f020bbc4b08024b0 1 parent 6bd414b
Nathan Day authored
Showing with 8 additions and 4 deletions.
  1. +6 −2 Classes/NDRotator.h
  2. +2 −2 Classes/NDRotator.m
8 Classes/NDRotator.h
View
@@ -47,7 +47,7 @@ enum NDRotatorStyle
/*!
@enum NDThumbTint
- @abstract Constants used to change the thumb tint, this can be used to make the thumb clearer for smaller rotator controls..
+ @abstract Constants used to change the thumb tint, this can be used to make the thumb clearer for smaller rotator controls.
*/
enum NDThumbTint
{
@@ -138,6 +138,9 @@ enum NDThumbTint
/*!
@property wrapAround
@abstract Contains the boolean used to determine how the rotator behaves when the user reaches minimumDomain or maximumDomain.
+ @discussion If wrapAround is YES then when the angular value reaches minimumDomain the angular value continues by wrapping the value up to maximumDomain, and similarly when the angular value reaches maximumDomain the angular value continues by wrapping the value down to minimumDomain. If NO then the rotator will simple stop when the minimumDomain or maximumDomain is reached. If wrapAround is YES and the difference between minimumDomain and maximumDomain is not exactly a multiple 2π then an undesired jump may occur.
+
+ The default value of this property is YES.
*/
@property BOOL wrapAround;
/*!
@@ -150,11 +153,12 @@ enum NDThumbTint
@property(nonatomic, getter=isContinuous) BOOL continuous;
/*!
@property thumbTint
+ @abstract Contains the value used to set the color of the thumb.
*/
@property(nonatomic) enum NDThumbTint thumbTint;
/*!
- @methodgroup methods and properties to override to change look
+ @methodgroup methods and properties to override to change, these methods are not yet finalized.
*/
@property(readonly) CGRect controlRect;
4 Classes/NDRotator.m
View
@@ -28,8 +28,8 @@
* const kMinimumDomainCodingKey = @"minimumDomain",
* const kMaximumDomainCodingKey = @"maximumDomain",
* const kThumbTintCodingKey = @"thumbTint",
- * const kContinuousCodingKey = YES,
- * const kWrapAroundCodingKey = YES;
+ * const kContinuousCodingKey = @"continuous",
+ * const kWrapAroundCodingKey = @"wrapAround";
static NSString * kRotatorStyleStrs[] = { @"disc", @"rotate", @"linear" };
static NSString * kThumbTintStr[] = { @"grey", @"red", @"green", @"blue", @"yellow", @"magenta", @"teal", @"orange", @"pink", @"lime", @"spring green", @"purple", @"aqua", @"black" };
Please sign in to comment.
Something went wrong with that request. Please try again.