diff --git a/AppKit/CPBox.j b/AppKit/CPBox.j index c3f39b0f6..06696c1da 100644 --- a/AppKit/CPBox.j +++ b/AppKit/CPBox.j @@ -436,16 +436,16 @@ CPBelowBottom = 6; - (void)drawRect:(CGRect)rect { - var bounds = CGRectMakeCopy([self bounds]); + var bounds = [self bounds]; switch (_boxType) { case CPBoxSeparator: // NSBox does not include a horizontal flag for the separator type. We have to determine // the type of separator to draw by the width and height of the frame. - if (CGRectGetWidth(bounds) === 5.0) + if (_CGRectGetWidth(bounds) === 5.0) return [self _drawVerticalSeparatorInRect:bounds]; - else if (CGRectGetHeight(bounds) === 5.0) + else if (_CGRectGetHeight(bounds) === 5.0) return [self _drawHorizontalSeparatorInRect:bounds]; break; @@ -492,8 +492,8 @@ CPBelowBottom = 6; CGContextSetStrokeColor(context, [self borderColor]); CGContextSetLineWidth(context, 1.0); - CGContextMoveToPoint(context, CGRectGetMinX(aRect), CGRectGetMidY(aRect)); - CGContextAddLineToPoint(context, CGRectGetWidth(aRect), CGRectGetMidY(aRect)); + CGContextMoveToPoint(context, _CGRectGetMinX(aRect), _CGRectGetMidY(aRect)); + CGContextAddLineToPoint(context, _CGRectGetWidth(aRect), _CGRectGetMidY(aRect)); CGContextStrokePath(context); } @@ -504,8 +504,8 @@ CPBelowBottom = 6; CGContextSetStrokeColor(context, [self borderColor]); CGContextSetLineWidth(context, 1.0); - CGContextMoveToPoint(context, CGRectGetMidX(aRect), CGRectGetMinY(aRect)); - CGContextAddLineToPoint(context, CGRectGetMidX(aRect), CGRectGetHeight(aRect)); + CGContextMoveToPoint(context, _CGRectGetMidX(aRect), _CGRectGetMinY(aRect)); + CGContextAddLineToPoint(context, _CGRectGetMidX(aRect), _CGRectGetHeight(aRect)); CGContextStrokePath(context); }