mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-11-13 02:08:55 +00:00
draw the bottom corner in CPScrollView
This commit is contained in:
1 parent
e77d28f761
commit
bcacee2147
1 file changed
+26
@@ -327,6 +327,9 @@
|
||||
[_headerClipView setFrame:headerClipViewFrame];
|
||||
[_cornerView setFrame:[self _cornerViewFrame]];
|
||||
|
||||
if (shouldShowHorizontalScroller && shouldShowVerticalScroller)
|
||||
[self setNeedsDisplay:YES];
|
||||
|
||||
--_recursionCount;
|
||||
}
|
||||
|
||||
@@ -782,6 +785,29 @@
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
if (![[self verticalScroller] isHidden] && ![[self horizontalScroller] isHidden])
|
||||
{
|
||||
var verticalScrollerFrame = [[self verticalScroller] frame],
|
||||
bottomCornerRect = CGRectMakeCopy(verticalScrollerFrame);
|
||||
|
||||
bottomCornerRect.origin.y = CGRectGetMaxY(verticalScrollerFrame);
|
||||
bottomCornerRect.size.height = [CPScroller scrollerWidth];
|
||||
|
||||
CGContextSetFillColor(context, [CPColor colorWithRed:242.0 / 255.0 green:242.0 / 255.0 blue:243.0 / 255.0 alpha:1.0]);
|
||||
CGContextFillRect(context, bottomCornerRect);
|
||||
|
||||
CGContextSetStrokeColor(context, [CPColor colorWithRed:184.0 / 255.0 green:184.0 / 255.0 blue:184.0 / 255.0 alpha:1.0]);
|
||||
|
||||
CGContextMoveToPoint(context, CGRectGetMinX(bottomCornerRect), CGRectGetMinY(bottomCornerRect));
|
||||
CGContextAddLineToPoint(context, CGRectGetMaxX(bottomCornerRect), CGRectGetMinY(bottomCornerRect));
|
||||
CGContextStrokePath(context);
|
||||
|
||||
CGContextMoveToPoint(context, CGRectGetMinX(bottomCornerRect), CGRectGetMinY(bottomCornerRect));
|
||||
CGContextAddLineToPoint(context, CGRectGetMinX(bottomCornerRect), CGRectGetMaxY(bottomCornerRect));
|
||||
CGContextStrokePath(context);
|
||||
}
|
||||
}
|
||||
|
||||
- (void)_drawGrayBezelInContext:(CGContext)context bounds:(CGRect)aRect
|
||||
|
||||
Reference in new issue
Block a user