Skip to content

Commit

Permalink
Fixing issue when building with SDKs prior to 7
Browse files Browse the repository at this point in the history
  • Loading branch information
HeshamMegid committed Nov 18, 2013
1 parent fe0c316 commit e928fbc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion HMSegmentedControl/HMSegmentedControl.m
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ - (void)updateSegmentsRects {
if (self.isScrollEnabled) {
if (self.type == HMSegmentedControlTypeText) {
for (NSString *titleString in self.sectionTitles) {
#if __IPHONE_OS_VERSION_MIN_REQUIRED >= __IPHONE_7_0
#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 70000
CGFloat stringWidth = [titleString sizeWithAttributes:@{NSFontAttributeName: self.font}].width + self.segmentEdgeInset.left + self.segmentEdgeInset.right;
#else
CGFloat stringWidth = [titleString sizeWithFont:self.font].width + self.segmentEdgeInset.left + self.segmentEdgeInset.right;
Expand Down

0 comments on commit e928fbc

Please sign in to comment.