summaryrefslogtreecommitdiffstats
path: root/Source/WebKit2/UIProcess/WebUIClient.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebKit2/UIProcess/WebUIClient.cpp')
-rw-r--r--Source/WebKit2/UIProcess/WebUIClient.cpp55
1 files changed, 54 insertions, 1 deletions
diff --git a/Source/WebKit2/UIProcess/WebUIClient.cpp b/Source/WebKit2/UIProcess/WebUIClient.cpp
index e95af34..9f2c7ab 100644
--- a/Source/WebKit2/UIProcess/WebUIClient.cpp
+++ b/Source/WebKit2/UIProcess/WebUIClient.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2010 Apple Inc. All rights reserved.
+ * Copyright (C) 2010, 2011 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -273,4 +273,57 @@ bool WebUIClient::decidePolicyForGeolocationPermissionRequest(WebPageProxy* page
return true;
}
+float WebUIClient::headerHeight(WebPageProxy* page, WebFrameProxy* frame)
+{
+ if (!m_client.headerHeight)
+ return 0;
+
+ return m_client.headerHeight(toAPI(page), toAPI(frame), m_client.clientInfo);
+}
+
+float WebUIClient::footerHeight(WebPageProxy* page, WebFrameProxy* frame)
+{
+ if (!m_client.footerHeight)
+ return 0;
+
+ return m_client.footerHeight(toAPI(page), toAPI(frame), m_client.clientInfo);
+}
+
+void WebUIClient::drawHeader(WebPageProxy* page, WebFrameProxy* frame, const WebCore::FloatRect& rect)
+{
+ if (!m_client.drawHeader)
+ return;
+
+ m_client.drawHeader(toAPI(page), toAPI(frame), toAPI(rect), m_client.clientInfo);
+}
+
+void WebUIClient::drawFooter(WebPageProxy* page, WebFrameProxy* frame, const WebCore::FloatRect& rect)
+{
+ if (!m_client.drawFooter)
+ return;
+
+ m_client.drawFooter(toAPI(page), toAPI(frame), toAPI(rect), m_client.clientInfo);
+}
+
+void WebUIClient::printFrame(WebPageProxy* page, WebFrameProxy* frame)
+{
+ if (!m_client.printFrame)
+ return;
+
+ m_client.printFrame(toAPI(page), toAPI(frame), m_client.clientInfo);
+}
+
+bool WebUIClient::canRunModal() const
+{
+ return m_client.runModal;
+}
+
+void WebUIClient::runModal(WebPageProxy* page)
+{
+ if (!m_client.runModal)
+ return;
+
+ m_client.runModal(toAPI(page), m_client.clientInfo);
+}
+
} // namespace WebKit