OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2006, 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2004, 2006, 2007, 2008 Apple Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
159 IntSize frameSize = IntSize([scrollView() frame].size); | 159 IntSize frameSize = IntSize([scrollView() frame].size); |
160 visibleContentRectIncludingObscuredArea.setSize(frameSize); | 160 visibleContentRectIncludingObscuredArea.setSize(frameSize); |
161 } | 161 } |
162 | 162 |
163 return visibleContentRectIncludingObscuredArea; | 163 return visibleContentRectIncludingObscuredArea; |
164 END_BLOCK_OBJC_EXCEPTIONS; | 164 END_BLOCK_OBJC_EXCEPTIONS; |
165 | 165 |
166 return IntRect(); | 166 return IntRect(); |
167 } | 167 } |
168 | 168 |
| 169 int ScrollView::platformWidgetHorizontalScrollbarIntrusion() const |
| 170 { |
| 171 if (!platformWidget()) |
| 172 return 0; |
| 173 |
| 174 return [scrollView() frame].size.width - [scrollView() documentVisibleRect].
size.width; |
| 175 } |
| 176 |
| 177 int ScrollView::platformWidgetVerticalScrollbarIntrusion() const |
| 178 { |
| 179 if (!platformWidget()) |
| 180 return 0; |
| 181 |
| 182 return [scrollView() frame].size.height - [scrollView() documentVisibleRect]
.size.height; |
| 183 } |
| 184 |
169 IntSize ScrollView::platformVisibleContentSizeIncludingObscuredArea(bool include
Scrollbars) const | 185 IntSize ScrollView::platformVisibleContentSizeIncludingObscuredArea(bool include
Scrollbars) const |
170 { | 186 { |
171 return platformVisibleContentRectIncludingObscuredArea(includeScrollbars).si
ze(); | 187 return platformVisibleContentRectIncludingObscuredArea(includeScrollbars).si
ze(); |
172 } | 188 } |
173 | 189 |
174 void ScrollView::platformSetContentsSize() | 190 void ScrollView::platformSetContentsSize() |
175 { | 191 { |
176 BEGIN_BLOCK_OBJC_EXCEPTIONS; | 192 BEGIN_BLOCK_OBJC_EXCEPTIONS; |
177 int w = m_contentsSize.width(); | 193 int w = m_contentsSize.width(); |
178 int h = m_contentsSize.height(); | 194 int h = m_contentsSize.height(); |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
275 } | 291 } |
276 | 292 |
277 void ScrollView::platformSetScrollOrigin(const IntPoint& origin, bool updatePosi
tionAtAll, bool updatePositionSynchronously) | 293 void ScrollView::platformSetScrollOrigin(const IntPoint& origin, bool updatePosi
tionAtAll, bool updatePositionSynchronously) |
278 { | 294 { |
279 BEGIN_BLOCK_OBJC_EXCEPTIONS; | 295 BEGIN_BLOCK_OBJC_EXCEPTIONS; |
280 [scrollView() setScrollOrigin:origin updatePositionAtAll:updatePositionAtAll
immediately:updatePositionSynchronously]; | 296 [scrollView() setScrollOrigin:origin updatePositionAtAll:updatePositionAtAll
immediately:updatePositionSynchronously]; |
281 END_BLOCK_OBJC_EXCEPTIONS; | 297 END_BLOCK_OBJC_EXCEPTIONS; |
282 } | 298 } |
283 | 299 |
284 } // namespace WebCore | 300 } // namespace WebCore |
OLD | NEW |