Commit 3f1a57fd authored by kov@webkit.org's avatar kov@webkit.org

2011-03-10 Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk>

        Reviewed by Kenneth Rohde Christiansen.

        Tiled backing store's delegated scroll request uses incorrect convention
        https://bugs.webkit.org/show_bug.cgi?id=56011

        Use a point instead of delta, when relaying the scroll request from
        ScrollView::setScrollPosition.

        * loader/EmptyClients.h:
        (WebCore::EmptyChromeClient::delegatedScrollRequested):
        * page/Chrome.cpp:
        (WebCore::Chrome::delegatedScrollRequested):
        * page/Chrome.h:
        * page/ChromeClient.h:
        * platform/HostWindow.h:
        * platform/ScrollView.cpp:
        (WebCore::ScrollView::setScrollPosition):
2011-03-10  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>

        Reviewed by Kenneth Rohde Christiansen.

        Tiled backing store's delegated scroll request uses incorrect convention
        https://bugs.webkit.org/show_bug.cgi?id=56011

        Adapt internal API to match the change from delta to point on the
        WebCore side, and convert the point to a delta for the public API.

        * WebCoreSupport/ChromeClientQt.cpp:
        (WebCore::ChromeClientQt::delegatedScrollRequested):
        * WebCoreSupport/ChromeClientQt.h:
2011-03-10  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>

        Reviewed by Kenneth Rohde Christiansen.

        Tiled backing store's delegated scroll request uses incorrect convention
        https://bugs.webkit.org/show_bug.cgi?id=56011

        Adapt all of the internal API to match the delta to point
        conversion at the WebCore side.

        * UIProcess/API/qt/qwkpage.cpp:
        (QWKPagePrivate::pageDidRequestScroll):
        * UIProcess/API/qt/qwkpage_p.h:
        * UIProcess/PageClient.h:
        * UIProcess/WebPageProxy.cpp:
        (WebKit::WebPageProxy::pageDidRequestScroll):
        * UIProcess/WebPageProxy.h:
        * UIProcess/WebPageProxy.messages.in:
        * WebProcess/WebCoreSupport/WebChromeClient.cpp:
        (WebKit::WebChromeClient::delegatedScrollRequested):
        * WebProcess/WebCoreSupport/WebChromeClient.h:
        * WebProcess/WebPage/WebPage.cpp:
        (WebKit::WebPage::pageDidRequestScroll):
        * WebProcess/WebPage/WebPage.h:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@80716 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 6148bfe2
2011-03-10 Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk>
Reviewed by Kenneth Rohde Christiansen.
Tiled backing store's delegated scroll request uses incorrect convention
https://bugs.webkit.org/show_bug.cgi?id=56011
Use a point instead of delta, when relaying the scroll request from
ScrollView::setScrollPosition.
* loader/EmptyClients.h:
(WebCore::EmptyChromeClient::delegatedScrollRequested):
* page/Chrome.cpp:
(WebCore::Chrome::delegatedScrollRequested):
* page/Chrome.h:
* page/ChromeClient.h:
* platform/HostWindow.h:
* platform/ScrollView.cpp:
(WebCore::ScrollView::setScrollPosition):
2011-03-10 Pavel Feldman <pfeldman@chromium.org>
Reviewed by Yury Semikhatsky.
......
......@@ -161,7 +161,7 @@ public:
virtual void invalidateContentsForSlowScroll(const IntRect&, bool) {};
virtual void scroll(const IntSize&, const IntRect&, const IntRect&) { }
#if ENABLE(TILED_BACKING_STORE)
virtual void delegatedScrollRequested(const IntSize&) { }
virtual void delegatedScrollRequested(const IntPoint&) { }
#endif
#if ENABLE(REQUEST_ANIMATION_FRAME)
virtual void scheduleAnimation() { }
......
......@@ -88,9 +88,9 @@ void Chrome::scroll(const IntSize& scrollDelta, const IntRect& rectToScroll, con
}
#if ENABLE(TILED_BACKING_STORE)
void Chrome::delegatedScrollRequested(const IntSize& scrollDelta)
void Chrome::delegatedScrollRequested(const IntPoint& scrollPoint)
{
m_client->delegatedScrollRequested(scrollDelta);
m_client->delegatedScrollRequested(scrollPoint);
}
#endif
......
......@@ -71,7 +71,7 @@ namespace WebCore {
virtual void invalidateContentsForSlowScroll(const IntRect&, bool);
virtual void scroll(const IntSize&, const IntRect&, const IntRect&);
#if ENABLE(TILED_BACKING_STORE)
virtual void delegatedScrollRequested(const IntSize& scrollDelta);
virtual void delegatedScrollRequested(const IntPoint& scrollPoint);
#endif
virtual IntPoint screenToWindow(const IntPoint&) const;
virtual IntRect windowToScreen(const IntRect&) const;
......
......@@ -143,7 +143,7 @@ namespace WebCore {
virtual void invalidateContentsForSlowScroll(const IntRect&, bool) = 0;
virtual void scroll(const IntSize&, const IntRect&, const IntRect&) = 0;
#if ENABLE(TILED_BACKING_STORE)
virtual void delegatedScrollRequested(const IntSize&) = 0;
virtual void delegatedScrollRequested(const IntPoint&) = 0;
#endif
virtual IntPoint screenToWindow(const IntPoint&) const = 0;
virtual IntRect windowToScreen(const IntRect&) const = 0;
......
......@@ -52,7 +52,7 @@ public:
#if ENABLE(TILED_BACKING_STORE)
// Requests the host to do the actual scrolling. This is only used in combination with a tiled backing store.
virtual void delegatedScrollRequested(const IntSize& scrollDelta) = 0;
virtual void delegatedScrollRequested(const IntPoint& scrollPoint) = 0;
#endif
// Methods for doing coordinate conversions to and from screen coordinates.
......
......@@ -378,7 +378,7 @@ void ScrollView::setScrollPosition(const IntPoint& scrollPoint)
#if ENABLE(TILED_BACKING_STORE)
if (delegatesScrolling()) {
hostWindow()->delegatedScrollRequested(IntSize(scrollPoint.x(), scrollPoint.y()));
hostWindow()->delegatedScrollRequested(scrollPoint);
if (!m_actualVisibleContentRect.isEmpty())
m_actualVisibleContentRect.setLocation(scrollPoint);
return;
......
2011-03-10 Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk>
Reviewed by Kenneth Rohde Christiansen.
Tiled backing store's delegated scroll request uses incorrect convention
https://bugs.webkit.org/show_bug.cgi?id=56011
Adapt internal API to match the change from delta to point on the
WebCore side, and convert the point to a delta for the public API.
* WebCoreSupport/ChromeClientQt.cpp:
(WebCore::ChromeClientQt::delegatedScrollRequested):
* WebCoreSupport/ChromeClientQt.h:
2011-03-09 Peter Kasting <pkasting@google.com>
Reviewed by Mihai Parparita.
......
......@@ -430,9 +430,10 @@ void ChromeClientQt::scroll(const IntSize& delta, const IntRect& scrollViewRect,
}
#if ENABLE(TILED_BACKING_STORE)
void ChromeClientQt::delegatedScrollRequested(const IntSize& delta)
void ChromeClientQt::delegatedScrollRequested(const IntPoint& point)
{
emit m_webPage->scrollRequested(delta.width(), delta.height(), QRect(QPoint(0, 0), m_webPage->viewportSize()));
QPoint currentPosition(m_webPage->mainFrame()->scrollPosition());
emit m_webPage->scrollRequested(point.x() - currentPosition.x(), point.y() - currentPosition.y(), QRect(QPoint(0, 0), m_webPage->viewportSize()));
}
#endif
......
......@@ -120,7 +120,7 @@ namespace WebCore {
virtual void invalidateContentsForSlowScroll(const IntRect&, bool);
virtual void scroll(const IntSize& scrollDelta, const IntRect& rectToScroll, const IntRect& clipRect);
#if ENABLE(TILED_BACKING_STORE)
virtual void delegatedScrollRequested(const IntSize& scrollDelta);
virtual void delegatedScrollRequested(const IntPoint& scrollPoint);
#endif
virtual IntPoint screenToWindow(const IntPoint&) const;
......
2011-03-10 Gustavo Noronha Silva <gustavo.noronha@collabora.co.uk>
Reviewed by Kenneth Rohde Christiansen.
Tiled backing store's delegated scroll request uses incorrect convention
https://bugs.webkit.org/show_bug.cgi?id=56011
Adapt all of the internal API to match the delta to point
conversion at the WebCore side.
* UIProcess/API/qt/qwkpage.cpp:
(QWKPagePrivate::pageDidRequestScroll):
* UIProcess/API/qt/qwkpage_p.h:
* UIProcess/PageClient.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::pageDidRequestScroll):
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::delegatedScrollRequested):
* WebProcess/WebCoreSupport/WebChromeClient.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::pageDidRequestScroll):
* WebProcess/WebPage/WebPage.h:
2011-03-10 Balazs Kelemen <kbalazs@webkit.org>
Reviewed by Andreas Kling.
......
......@@ -194,9 +194,9 @@ void QWKPagePrivate::exitAcceleratedCompositingMode()
// FIXME: Implement.
}
void QWKPagePrivate::pageDidRequestScroll(const IntSize& delta)
void QWKPagePrivate::pageDidRequestScroll(const IntPoint& point)
{
emit q->scrollRequested(delta.width(), delta.height());
emit q->scrollRequested(point.x(), point.y());
}
void QWKPagePrivate::didChangeContentsSize(const IntSize& newSize)
......
......@@ -63,7 +63,7 @@ public:
virtual void enterAcceleratedCompositingMode(const LayerTreeContext&);
virtual void exitAcceleratedCompositingMode();
#endif // USE(ACCELERATED_COMPOSITING)
virtual void pageDidRequestScroll(const WebCore::IntSize&);
virtual void pageDidRequestScroll(const WebCore::IntPoint&);
virtual void processDidCrash();
virtual void pageClosed() { }
virtual void didRelaunchProcess();
......
......@@ -86,7 +86,7 @@ public:
virtual void toolTipChanged(const String&, const String&) = 0;
#if ENABLE(TILED_BACKING_STORE)
virtual void pageDidRequestScroll(const WebCore::IntSize&) = 0;
virtual void pageDidRequestScroll(const WebCore::IntPoint&) = 0;
#endif
#if PLATFORM(QT)
virtual void didChangeContentsSize(const WebCore::IntSize&) = 0;
......
......@@ -1924,9 +1924,9 @@ void WebPageProxy::runBeforeUnloadConfirmPanel(const String& message, uint64_t f
}
#if ENABLE(TILED_BACKING_STORE)
void WebPageProxy::pageDidRequestScroll(const IntSize& delta)
void WebPageProxy::pageDidRequestScroll(const IntPoint& point)
{
m_pageClient->pageDidRequestScroll(delta);
m_pageClient->pageDidRequestScroll(point);
}
#endif
......
......@@ -557,7 +557,7 @@ private:
void reattachToWebProcessWithItem(WebBackForwardListItem*);
#if ENABLE(TILED_BACKING_STORE)
void pageDidRequestScroll(const WebCore::IntSize&);
void pageDidRequestScroll(const WebCore::IntPoint&);
#endif
#if PLATFORM(QT)
......
......@@ -60,7 +60,7 @@ messages -> WebPageProxy {
DidChangeScrollOffsetPinningForMainFrame(bool hasHorizontalScrollbar, bool hasVerticalScrollbar)
#if ENABLE(TILED_BACKING_STORE)
PageDidRequestScroll(WebCore::IntSize delta)
PageDidRequestScroll(WebCore::IntPoint point)
#endif
#if PLATFORM(QT)
DidChangeContentsSize(WebCore::IntSize newSize)
......
......@@ -374,7 +374,7 @@ void WebChromeClient::scroll(const IntSize& scrollOffset, const IntRect& scrollR
}
#if ENABLE(TILED_BACKING_STORE)
void WebChromeClient::delegatedScrollRequested(const IntSize& scrollOffset)
void WebChromeClient::delegatedScrollRequested(const IntPoint& scrollOffset)
{
m_page->pageDidRequestScroll(scrollOffset);
}
......
......@@ -113,7 +113,7 @@ private:
virtual void invalidateContentsForSlowScroll(const WebCore::IntRect&, bool);
virtual void scroll(const WebCore::IntSize& scrollOffset, const WebCore::IntRect& scrollRect, const WebCore::IntRect& clipRect);
#if ENABLE(TILED_BACKING_STORE)
virtual void delegatedScrollRequested(const WebCore::IntSize& scrollOffset);
virtual void delegatedScrollRequested(const WebCore::IntPoint& scrollOffset);
#endif
virtual WebCore::IntPoint screenToWindow(const WebCore::IntPoint&) const;
virtual WebCore::IntRect windowToScreen(const WebCore::IntRect&) const;
......
......@@ -789,9 +789,9 @@ void WebPage::pageDidScroll()
}
#if ENABLE(TILED_BACKING_STORE)
void WebPage::pageDidRequestScroll(const IntSize& delta)
void WebPage::pageDidRequestScroll(const IntPoint& point)
{
send(Messages::WebPageProxy::PageDidRequestScroll(delta));
send(Messages::WebPageProxy::PageDidRequestScroll(point));
}
#endif
......
......@@ -256,7 +256,7 @@ public:
void pageDidScroll();
#if ENABLE(TILED_BACKING_STORE)
void pageDidRequestScroll(const WebCore::IntSize& delta);
void pageDidRequestScroll(const WebCore::IntPoint&);
void setActualVisibleContentRect(const WebCore::IntRect&);
bool resizesToContentsEnabled() const { return !m_resizesToContentsLayoutSize.isEmpty(); }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment