| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights
reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights
reserved. |
| 3 * | 3 * |
| 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. | 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. |
| 5 * | 5 * |
| 6 * Other contributors: | 6 * Other contributors: |
| 7 * Robert O'Callahan <roc+@cs.cmu.edu> | 7 * Robert O'Callahan <roc+@cs.cmu.edu> |
| 8 * David Baron <dbaron@fas.harvard.edu> | 8 * David Baron <dbaron@fas.harvard.edu> |
| 9 * Christian Biesinger <cbiesinger@web.de> | 9 * Christian Biesinger <cbiesinger@web.de> |
| 10 * Randall Jesup <rjesup@wgate.com> | 10 * Randall Jesup <rjesup@wgate.com> |
| (...skipping 1443 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1454 } | 1454 } |
| 1455 | 1455 |
| 1456 void RenderLayerScrollableArea::updateCompositingLayersAfterScroll() | 1456 void RenderLayerScrollableArea::updateCompositingLayersAfterScroll() |
| 1457 { | 1457 { |
| 1458 RenderLayerCompositor* compositor = box().view()->compositor(); | 1458 RenderLayerCompositor* compositor = box().view()->compositor(); |
| 1459 if (compositor->inCompositingMode()) { | 1459 if (compositor->inCompositingMode()) { |
| 1460 if (usesCompositedScrolling()) { | 1460 if (usesCompositedScrolling()) { |
| 1461 DisableCompositingQueryAsserts disabler; | 1461 DisableCompositingQueryAsserts disabler; |
| 1462 ASSERT(box().hasCompositedLayerMapping()); | 1462 ASSERT(box().hasCompositedLayerMapping()); |
| 1463 box().compositedLayerMapping()->setNeedsGraphicsLayerUpdate(); | 1463 box().compositedLayerMapping()->setNeedsGraphicsLayerUpdate(); |
| 1464 compositor->setNeedsCompositingUpdate(CompositingUpdateOnCompositedS
croll); | 1464 compositor->setNeedsCompositingUpdate(CompositingUpdateAfterGeometry
Change); |
| 1465 } else { | 1465 } else { |
| 1466 layer()->setNeedsCompositingInputsUpdate(); | 1466 layer()->setNeedsCompositingInputsUpdate(); |
| 1467 compositor->setNeedsCompositingUpdate(CompositingUpdateAfterComposit
ingInputChange); | 1467 compositor->setNeedsCompositingUpdate(CompositingUpdateAfterComposit
ingInputChange); |
| 1468 } | 1468 } |
| 1469 } | 1469 } |
| 1470 } | 1470 } |
| 1471 | 1471 |
| 1472 bool RenderLayerScrollableArea::usesCompositedScrolling() const | 1472 bool RenderLayerScrollableArea::usesCompositedScrolling() const |
| 1473 { | 1473 { |
| 1474 // Scroll form controls on the main thread so they exhibit correct touch scr
oll event bubbling | 1474 // Scroll form controls on the main thread so they exhibit correct touch scr
oll event bubbling |
| 1475 if (box().isIntristicallyScrollable(VerticalScrollbar) || box().isIntristica
llyScrollable(HorizontalScrollbar)) | 1475 if (box().isIntristicallyScrollable(VerticalScrollbar) || box().isIntristica
llyScrollable(HorizontalScrollbar)) |
| 1476 return false; | 1476 return false; |
| 1477 | 1477 |
| 1478 // See https://codereview.chromium.org/176633003/ for the tests that fail wi
thout this disabler. | 1478 // See https://codereview.chromium.org/176633003/ for the tests that fail wi
thout this disabler. |
| 1479 DisableCompositingQueryAsserts disabler; | 1479 DisableCompositingQueryAsserts disabler; |
| 1480 return box().hasCompositedLayerMapping() && box().compositedLayerMapping()->
scrollingLayer(); | 1480 return box().hasCompositedLayerMapping() && box().compositedLayerMapping()->
scrollingLayer(); |
| 1481 } | 1481 } |
| 1482 | 1482 |
| 1483 bool RenderLayerScrollableArea::needsCompositedScrolling() const | 1483 bool RenderLayerScrollableArea::needsCompositedScrolling() const |
| 1484 { | 1484 { |
| 1485 return scrollsOverflow() && box().view()->compositor()->acceleratedCompositi
ngForOverflowScrollEnabled(); | 1485 return scrollsOverflow() && box().view()->compositor()->acceleratedCompositi
ngForOverflowScrollEnabled(); |
| 1486 } | 1486 } |
| 1487 | 1487 |
| 1488 } // Namespace WebCore | 1488 } // Namespace WebCore |
| OLD | NEW |