Created
July 10, 2009 17:05
-
-
Save philk/144626 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (void)updateInterface { | |
if ([myPoly numberOfSides] > [myPoly minimumNumberOfSides]) { | |
decreaseButton.enabled = YES; | |
} | |
if ([myPoly numberOfSides] < [myPoly maximumNumberOfSides]) { | |
increaseButton.enabled = YES; | |
} | |
if ([myPoly numberOfSides] == [myPoly minimumNumberOfSides]) { | |
decreaseButton.enabled = NO; | |
} else if ([myPoly numberOfSides] == [myPoly maximumNumberOfSides]) { | |
increaseButton.enabled = NO; | |
} | |
numberOfSidesLabel.text = [NSString stringWithFormat:@"%d", [myPoly numberOfSides]]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment