LEFT | RIGHT |
1 /* | 1 /* |
2 * Copyright (C) 2006-2017 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006-2017 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 283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
294 | 294 |
295 IntSize ScrollView::fixedLayoutSize() const | 295 IntSize ScrollView::fixedLayoutSize() const |
296 { | 296 { |
297 return m_fixedLayoutSize; | 297 return m_fixedLayoutSize; |
298 } | 298 } |
299 | 299 |
300 void ScrollView::setFixedLayoutSize(const IntSize& newSize) | 300 void ScrollView::setFixedLayoutSize(const IntSize& newSize) |
301 { | 301 { |
302 if (fixedLayoutSize() == newSize) | 302 if (fixedLayoutSize() == newSize) |
303 return; | 303 return; |
| 304 |
| 305 LOG_WITH_STREAM(Layout, stream << "ScrollView " << this << " setFixedLayoutS
ize " << newSize); |
304 m_fixedLayoutSize = newSize; | 306 m_fixedLayoutSize = newSize; |
305 if (m_useFixedLayout) | 307 if (m_useFixedLayout) |
306 availableContentSizeChanged(AvailableSizeChangeReason::AreaSizeChanged); | 308 availableContentSizeChanged(AvailableSizeChangeReason::AreaSizeChanged); |
307 } | 309 } |
308 | 310 |
309 bool ScrollView::useFixedLayout() const | 311 bool ScrollView::useFixedLayout() const |
310 { | 312 { |
311 return m_useFixedLayout; | 313 return m_useFixedLayout; |
312 } | 314 } |
313 | 315 |
(...skipping 1130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1444 } | 1446 } |
1445 | 1447 |
1446 IntPoint ScrollView::locationOfContents() const | 1448 IntPoint ScrollView::locationOfContents() const |
1447 { | 1449 { |
1448 IntPoint result = location(); | 1450 IntPoint result = location(); |
1449 if (shouldPlaceBlockDirectionScrollbarOnLeft() && m_verticalScrollbar) | 1451 if (shouldPlaceBlockDirectionScrollbarOnLeft() && m_verticalScrollbar) |
1450 result.move(m_verticalScrollbar->occupiedWidth(), 0); | 1452 result.move(m_verticalScrollbar->occupiedWidth(), 0); |
1451 return result; | 1453 return result; |
1452 } | 1454 } |
1453 | 1455 |
| 1456 int ScrollView::horizontalScrollbarIntrusion(IntrusionIncludesPlatformWidgetScro
llbars intrusionIncludesPlatformWidgetScrollbars) const |
| 1457 { |
| 1458 int intrusion = ScrollableArea::horizontalScrollbarIntrusion(); |
| 1459 if (platformWidget() && intrusionIncludesPlatformWidgetScrollbars == Include
PlatformWidgetScrollbars) |
| 1460 intrusion += platformWidgetHorizontalScrollbarIntrusion(); |
| 1461 return intrusion; |
| 1462 } |
| 1463 |
| 1464 int ScrollView::verticalScrollbarIntrusion(IntrusionIncludesPlatformWidgetScroll
bars intrusionIncludesPlatformWidgetScrollbars) const |
| 1465 { |
| 1466 int intrusion = ScrollableArea::verticalScrollbarIntrusion(); |
| 1467 if (platformWidget() && intrusionIncludesPlatformWidgetScrollbars == Include
PlatformWidgetScrollbars) |
| 1468 intrusion += platformWidgetVerticalScrollbarIntrusion(); |
| 1469 return intrusion; |
| 1470 } |
| 1471 |
1454 #if !PLATFORM(COCOA) | 1472 #if !PLATFORM(COCOA) |
1455 | 1473 |
1456 void ScrollView::platformAddChild(Widget*) | 1474 void ScrollView::platformAddChild(Widget*) |
1457 { | 1475 { |
1458 } | 1476 } |
1459 | 1477 |
1460 void ScrollView::platformRemoveChild(Widget*) | 1478 void ScrollView::platformRemoveChild(Widget*) |
1461 { | 1479 { |
1462 } | 1480 } |
1463 | 1481 |
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1567 } | 1585 } |
1568 | 1586 |
1569 bool ScrollView::platformIsOffscreen() const | 1587 bool ScrollView::platformIsOffscreen() const |
1570 { | 1588 { |
1571 return false; | 1589 return false; |
1572 } | 1590 } |
1573 | 1591 |
1574 #endif | 1592 #endif |
1575 | 1593 |
1576 } | 1594 } |
LEFT | RIGHT |