Changeset 53490 in webkit
- Timestamp:
- Jan 19, 2010 1:53:43 PM (14 years ago)
- Location:
- trunk/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r53489 r53490 1 2010-01-19 Daniel Bates <dbates@rim.com> 2 3 Reviewed by Darin Adler. 4 5 https://bugs.webkit.org/show_bug.cgi?id=33851 6 7 Fixes an issue in the Apple Mac port where ScrollView::platformVisibleContentRect 8 returns the rectangle of the document within the content view of 9 the scroll view (i.e. the rectangle not including scrollbars) when 10 the parameter includeScrollbars == true 11 12 Currently, this behavior contradicts both the comment in ScrollView.h 13 for method visibleContentRect as well as the behavior in 14 ScrollView::visibleContentRect() for a platform-independent scroll view. 15 16 Instead, it should return the rectangle whose dimensions include 17 the scrollbars. 18 19 Also, removes some extra whitespace at the end of the lines. 20 21 No tests included because we cannot test this using either DRT 22 or a manual test. 23 24 * platform/mac/ScrollViewMac.mm: 25 (WebCore::ScrollView::platformVisibleContentRect): If includeScrollbars == true 26 then return the rectangle whose dimensions are that of 27 the frame (i.e. -[NSScrollView frame]). 28 1 29 2010-01-19 Steve Block <steveblock@google.com> 2 30 -
trunk/WebCore/platform/mac/ScrollViewMac.mm
r52489 r53490 108 108 IntRect ScrollView::platformVisibleContentRect(bool includeScrollbars) const 109 109 { 110 BEGIN_BLOCK_OBJC_EXCEPTIONS; 111 if (includeScrollbars) { 112 if (NSView* documentView = this->documentView()) 113 return enclosingIntRect([documentView visibleRect]); 114 } 115 return enclosingIntRect([scrollView() documentVisibleRect]); 116 END_BLOCK_OBJC_EXCEPTIONS; 110 BEGIN_BLOCK_OBJC_EXCEPTIONS; 111 IntRect result = enclosingIntRect([scrollView() documentVisibleRect]); 112 if (includeScrollbars) 113 result.setSize(IntSize([scrollView() frame].size)); 114 return result; 115 END_BLOCK_OBJC_EXCEPTIONS; 117 116 return IntRect(); 118 117 }
Note: See TracChangeset
for help on using the changeset viewer.