[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
andersca at apple.com
andersca at apple.com
Wed Dec 22 14:58:45 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 12ee8e2183f6b1f79c972665af897e50339888bb
Author: andersca at apple.com <andersca at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue Oct 26 20:28:44 2010 +0000
WebKit2: pageDidScroll callback should be on the UI process client rather than (or in addition to) the web process client
https://bugs.webkit.org/show_bug.cgi?id=48366
Reviewed by Sam Weinig.
* UIProcess/API/qt/qwkpage.cpp:
(QWKPage::QWKPage):
Add zero initializer.
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::pageDidScroll):
Call the pageDidScroll client function.
* UIProcess/WebPageProxy.messages.in:
Add PageDidScroll message.
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::pageDidScroll):
Send the PageDidScroll message.
WebKitTools: pageDidScroll callback should be on the UI process client rather than (or in addition to) the web process client
https://bugs.webkit.org/show_bug.cgi?id=48366
<rdar://problem/8595202>
Reviewed by Sam Weinig.
* MiniBrowser/mac/BrowserWindowController.m:
(-[BrowserWindowController awakeFromNib]):
* WebKitTestRunner/TestController.cpp:
(WTR::createOtherPage):
(WTR::TestController::initialize):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70564 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
index 44ef013..a5e8b4d 100644
--- a/WebKit2/ChangeLog
+++ b/WebKit2/ChangeLog
@@ -1,3 +1,25 @@
+2010-10-26 Anders Carlsson <andersca at apple.com>
+
+ Reviewed by Sam Weinig.
+
+ pageDidScroll callback should be on the UI process client rather than (or in addition to) the web process client
+ https://bugs.webkit.org/show_bug.cgi?id=48366
+
+ * UIProcess/API/qt/qwkpage.cpp:
+ (QWKPage::QWKPage):
+ Add zero initializer.
+
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::pageDidScroll):
+ Call the pageDidScroll client function.
+
+ * UIProcess/WebPageProxy.messages.in:
+ Add PageDidScroll message.
+
+ * WebProcess/WebPage/WebPage.cpp:
+ (WebKit::WebPage::pageDidScroll):
+ Send the PageDidScroll message.
+
2010-10-26 Brian Weinstein <bweinstein at apple.com>
Reviewed by Darin Adler.
diff --git a/WebKit2/UIProcess/API/C/WKPage.h b/WebKit2/UIProcess/API/C/WKPage.h
index d5d386c..8c640a0 100644
--- a/WebKit2/UIProcess/API/C/WKPage.h
+++ b/WebKit2/UIProcess/API/C/WKPage.h
@@ -142,7 +142,9 @@ typedef void (*WKPageDidNotHandleKeyEventCallback)(WKPageRef page, WKNativeEvent
typedef WKRect (*WKPageGetWindowFrameCallback)(WKPageRef page, const void *clientInfo);
typedef void (*WKPageSetWindowFrameCallback)(WKPageRef page, WKRect frame, const void *clientInfo);
typedef bool (*WKPageRunBeforeUnloadConfirmPanelCallback)(WKPageRef page, WKStringRef message, WKFrameRef frame, const void *clientInfo);
-typedef void (*WKPageDidDraw)(WKPageRef page, const void *clientInfo);
+typedef void (*WKPageDidDrawCallback)(WKPageRef page, const void *clientInfo);
+typedef void (*WKPageDidScrollCallback)(WKPageRef page, const void *clientInfo);
+
struct WKPageUIClient {
int version;
@@ -160,7 +162,8 @@ struct WKPageUIClient {
WKPageGetWindowFrameCallback getWindowFrame;
WKPageSetWindowFrameCallback setWindowFrame;
WKPageRunBeforeUnloadConfirmPanelCallback runBeforeUnloadConfirmPanel;
- WKPageDidDraw didDraw;
+ WKPageDidDrawCallback didDraw;
+ WKPageDidScrollCallback pageDidScroll;
};
typedef struct WKPageUIClient WKPageUIClient;
diff --git a/WebKit2/UIProcess/API/qt/qwkpage.cpp b/WebKit2/UIProcess/API/qt/qwkpage.cpp
index 272d0fc..64dedd6 100644
--- a/WebKit2/UIProcess/API/qt/qwkpage.cpp
+++ b/WebKit2/UIProcess/API/qt/qwkpage.cpp
@@ -310,7 +310,8 @@ QWKPage::QWKPage(WKPageNamespaceRef namespaceRef)
0, /* getWindowFrame */
0, /* setWindowFrame */
0, /* runBeforeUnloadConfirmPanel */
- 0 /* didDraw */
+ 0, /* didDraw */
+ 0 /* pageDidScroll */
};
WKPageSetPageUIClient(pageRef(), &uiClient);
}
diff --git a/WebKit2/UIProcess/WebPageProxy.cpp b/WebKit2/UIProcess/WebPageProxy.cpp
index f20cec5..da37689 100644
--- a/WebKit2/UIProcess/WebPageProxy.cpp
+++ b/WebKit2/UIProcess/WebPageProxy.cpp
@@ -919,6 +919,11 @@ void WebPageProxy::didChangeViewportData(const ViewportArguments& args)
m_pageClient->setViewportArguments(args);
}
+void WebPageProxy::pageDidScroll()
+{
+ m_uiClient.pageDidScroll(this);
+}
+
void WebPageProxy::didDraw()
{
m_uiClient.didDraw(this);
diff --git a/WebKit2/UIProcess/WebPageProxy.h b/WebKit2/UIProcess/WebPageProxy.h
index e3ba662..8b5983f 100644
--- a/WebKit2/UIProcess/WebPageProxy.h
+++ b/WebKit2/UIProcess/WebPageProxy.h
@@ -274,6 +274,7 @@ private:
void canRunBeforeUnloadConfirmPanel(bool& canRun);
void runBeforeUnloadConfirmPanel(const String& message, uint64_t frameID, bool& shouldClose);
void didChangeViewportData(const WebCore::ViewportArguments&);
+ void pageDidScroll();
// Back/Forward list management
void backForwardAddItem(uint64_t itemID);
diff --git a/WebKit2/UIProcess/WebPageProxy.messages.in b/WebKit2/UIProcess/WebPageProxy.messages.in
index fcf1ff8..17e6473 100644
--- a/WebKit2/UIProcess/WebPageProxy.messages.in
+++ b/WebKit2/UIProcess/WebPageProxy.messages.in
@@ -41,6 +41,7 @@ messages -> WebPageProxy {
GetWindowFrame() -> (WebCore::FloatRect windowFrame)
CanRunBeforeUnloadConfirmPanel() -> (bool canRun)
RunBeforeUnloadConfirmPanel(WTF::String message, uint64_t frameID) -> (bool shouldClose)
+ PageDidScroll()
# Policy messages.
DecidePolicyForMIMEType(uint64_t frameID, WTF::String MIMEType, WTF::String url, uint64_t listenerID)
diff --git a/WebKit2/UIProcess/WebUIClient.cpp b/WebKit2/UIProcess/WebUIClient.cpp
index 68eb4b9..c098dff 100644
--- a/WebKit2/UIProcess/WebUIClient.cpp
+++ b/WebKit2/UIProcess/WebUIClient.cpp
@@ -191,8 +191,15 @@ void WebUIClient::didDraw(WebPageProxy* page)
if (!m_pageUIClient.didDraw)
return;
- return m_pageUIClient.didDraw(toAPI(page), m_pageUIClient.clientInfo);
+ m_pageUIClient.didDraw(toAPI(page), m_pageUIClient.clientInfo);
}
+void WebUIClient::pageDidScroll(WebPageProxy* page)
+{
+ if (!m_pageUIClient.pageDidScroll)
+ return;
+
+ m_pageUIClient.pageDidScroll(toAPI(page), m_pageUIClient.clientInfo);
+}
} // namespace WebKit
diff --git a/WebKit2/UIProcess/WebUIClient.h b/WebKit2/UIProcess/WebUIClient.h
index 7e32173..72aedde 100644
--- a/WebKit2/UIProcess/WebUIClient.h
+++ b/WebKit2/UIProcess/WebUIClient.h
@@ -69,6 +69,7 @@ public:
bool runBeforeUnloadConfirmPanel(WebPageProxy*, const String&, WebFrameProxy*);
void didDraw(WebPageProxy*);
+ void pageDidScroll(WebPageProxy*);
private:
WKPageUIClient m_pageUIClient;
diff --git a/WebKit2/WebProcess/WebPage/WebPage.cpp b/WebKit2/WebProcess/WebPage/WebPage.cpp
index eb860e4..8a9ca20 100644
--- a/WebKit2/WebProcess/WebPage/WebPage.cpp
+++ b/WebKit2/WebProcess/WebPage/WebPage.cpp
@@ -455,6 +455,8 @@ void WebPage::pageDidScroll()
m_findController.hideFindIndicator();
m_uiClient.pageDidScroll(this);
+
+ WebProcess::shared().connection()->send(Messages::WebPageProxy::PageDidScroll(), m_pageID);
}
// Events
diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog
index 223ce57..6a0e470 100644
--- a/WebKitTools/ChangeLog
+++ b/WebKitTools/ChangeLog
@@ -1,3 +1,17 @@
+2010-10-26 Anders Carlsson <andersca at apple.com>
+
+ Reviewed by Sam Weinig.
+
+ pageDidScroll callback should be on the UI process client rather than (or in addition to) the web process client
+ https://bugs.webkit.org/show_bug.cgi?id=48366
+ <rdar://problem/8595202>
+
+ * MiniBrowser/mac/BrowserWindowController.m:
+ (-[BrowserWindowController awakeFromNib]):
+ * WebKitTestRunner/TestController.cpp:
+ (WTR::createOtherPage):
+ (WTR::TestController::initialize):
+
2010-10-26 Eric Seidel <eric at webkit.org>
Reviewed by Tony Chang.
diff --git a/WebKitTools/MiniBrowser/mac/BrowserWindowController.m b/WebKitTools/MiniBrowser/mac/BrowserWindowController.m
index ca871e9..b422478 100644
--- a/WebKitTools/MiniBrowser/mac/BrowserWindowController.m
+++ b/WebKitTools/MiniBrowser/mac/BrowserWindowController.m
@@ -582,7 +582,8 @@ static bool runBeforeUnloadConfirmPanel(WKPageRef page, WKStringRef message, WKF
getWindowFrame,
setWindowFrame,
runBeforeUnloadConfirmPanel,
- 0 /* didDraw */
+ 0, /* didDraw */
+ 0 /* pageDidScroll */
};
WKPageSetPageUIClient(_webView.pageRef, &uiClient);
}
diff --git a/WebKitTools/WebKitTestRunner/TestController.cpp b/WebKitTools/WebKitTestRunner/TestController.cpp
index 495712b..3186355 100644
--- a/WebKitTools/WebKitTestRunner/TestController.cpp
+++ b/WebKitTools/WebKitTestRunner/TestController.cpp
@@ -121,7 +121,8 @@ static WKPageRef createOtherPage(WKPageRef oldPage, WKDictionaryRef, WKEventModi
getWindowFrameOtherPage,
setWindowFrameOtherPage,
0, // runBeforeUnloadConfirmPanel
- 0 // didDraw
+ 0, // didDraw
+ 0 // pageDidScroll
};
WKPageSetPageUIClient(newPage, &otherPageUIClient);
@@ -206,7 +207,8 @@ void TestController::initialize(int argc, const char* argv[])
getWindowFrameMainPage,
setWindowFrameMainPage,
0, // runBeforeUnloadConfirmPanel
- 0 // didDraw
+ 0, // didDraw
+ 0 // pageDidScroll
};
WKPageSetPageUIClient(m_mainWebView->page(), &pageUIClient);
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list