Changeset 70509 in webkit
- Timestamp:
- Oct 25, 2010 6:06:30 PM (13 years ago)
- Location:
- trunk
- Files:
-
- 5 added
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r70508 r70509 1 2010-10-25 Simon Fraser <simon.fraser@apple.com> 2 3 Reviewed by Dan Bernstein. 4 5 Fix scrolling of noncomposited iframes within composited document 6 https://bugs.webkit.org/show_bug.cgi?id=47391 7 8 Testcase for scrolling a transformed iframe inside a compositing layer. 9 10 * compositing/iframes/composited-iframe-scroll-expected.checksum: Added. 11 * compositing/iframes/composited-iframe-scroll-expected.png: Added. 12 * compositing/iframes/composited-iframe-scroll-expected.txt: Added. 13 * compositing/iframes/composited-iframe-scroll.html: Added. 14 * compositing/iframes/resources/green-red-subframe.html: Added. 15 1 16 2010-10-25 Kenneth Russell <kbr@google.com> 2 17 -
trunk/WebCore/ChangeLog
r70503 r70509 1 2010-10-25 Simon Fraser <simon.fraser@apple.com> 2 3 Reviewed by Dan Bernstein. 4 5 Fix scrolling of noncomposited iframes within composited document 6 https://bugs.webkit.org/show_bug.cgi?id=47391 7 8 When an iframe that is painting into a compositing layer is scrolled, 9 we need to repaint via the RenderObject (which dirties the compositing layer contents), 10 rather than going out to hostWindow. 11 12 Test: compositing/iframes/composited-iframe-scroll.html 13 14 * page/FrameView.cpp: 15 (WebCore::FrameView::scrollContentsSlowPath): 16 * page/FrameView.h: 17 * platform/ScrollView.cpp: 18 (WebCore::ScrollView::scrollContents): 19 (WebCore::ScrollView::scrollContentsSlowPath): 20 * platform/ScrollView.h: 21 1 22 2010-10-25 Ryosuke Niwa <rniwa@webkit.org> 2 23 -
trunk/WebCore/page/FrameView.cpp
r70143 r70509 1001 1001 } 1002 1002 1003 void FrameView::scrollContentsSlowPath(const IntRect& updateRect) 1004 { 1005 #if USE(ACCELERATED_COMPOSITING) 1006 if (RenderPart* frameRenderer = m_frame->ownerRenderer()) { 1007 if (frameRenderer->containerForRepaint()) { 1008 IntRect rect(frameRenderer->borderLeft() + frameRenderer->paddingLeft(), 1009 frameRenderer->borderTop() + frameRenderer->paddingTop(), 1010 visibleWidth(), visibleHeight()); 1011 frameRenderer->repaintRectangle(rect); 1012 return; 1013 } 1014 } 1015 #endif 1016 1017 ScrollView::scrollContentsSlowPath(updateRect); 1018 } 1019 1003 1020 // Note that this gets called at painting time. 1004 1021 void FrameView::setIsOverlapped(bool isOverlapped) -
trunk/WebCore/page/FrameView.h
r69896 r70509 243 243 protected: 244 244 virtual bool scrollContentsFastPath(const IntSize& scrollDelta, const IntRect& rectToScroll, const IntRect& clipRect); 245 245 virtual void scrollContentsSlowPath(const IntRect& updateRect); 246 246 247 private: 247 248 FrameView(Frame*); -
trunk/WebCore/platform/ScrollView.cpp
r70143 r70509 536 536 537 537 if (m_drawPanScrollIcon) { 538 // FIXME: the pan icon is broken when accelerated compositing is on, since it will draw under the compositing layers. 539 // https://bugs.webkit.org/show_bug.cgi?id=47837 538 540 int panIconDirtySquareSizeLength = 2 * (panIconSizeLength + max(abs(scrollDelta.width()), abs(scrollDelta.height()))); // We only want to repaint what's necessary 539 541 IntPoint panIconDirtySquareLocation = IntPoint(m_panScrollIconPoint.x() - (panIconDirtySquareSizeLength / 2), m_panScrollIconPoint.y() - (panIconDirtySquareSizeLength / 2)); … … 546 548 // FIXME: Find a way to scroll subframes with this faster path 547 549 if (!scrollContentsFastPath(-scrollDelta, scrollViewRect, clipRect)) 548 hostWindow()->invalidateContentsForSlowScroll(updateRect, false);550 scrollContentsSlowPath(updateRect); 549 551 } else { 550 552 // We need to go ahead and repaint the entire backing store. Do it now before moving the 551 553 // windowed plugins. 552 hostWindow()->invalidateContentsForSlowScroll(updateRect, false);554 scrollContentsSlowPath(updateRect); 553 555 } 554 556 … … 564 566 hostWindow()->scroll(scrollDelta, rectToScroll, clipRect); 565 567 return true; 568 } 569 570 void ScrollView::scrollContentsSlowPath(const IntRect& updateRect) 571 { 572 hostWindow()->invalidateContentsForSlowScroll(updateRect, false); 566 573 } 567 574 -
trunk/WebCore/platform/ScrollView.h
r68557 r70509 265 265 virtual void paintScrollCorner(GraphicsContext*, const IntRect& cornerRect); 266 266 267 // Scroll the content by blitting the pixels 267 // Scroll the content by blitting the pixels. 268 268 virtual bool scrollContentsFastPath(const IntSize& scrollDelta, const IntRect& rectToScroll, const IntRect& clipRect); 269 // Scroll the content by invalidating everything. 270 virtual void scrollContentsSlowPath(const IntRect& updateRect); 269 271 270 272 private:
Note: See TracChangeset
for help on using the changeset viewer.