| Index: webkit/glue/webview_delegate.h
|
| ===================================================================
|
| --- webkit/glue/webview_delegate.h (revision 20851)
|
| +++ webkit/glue/webview_delegate.h (working copy)
|
| @@ -29,9 +29,10 @@
|
| #include <vector>
|
|
|
| #include "base/gfx/native_widget_types.h"
|
| +#include "webkit/api/public/WebNavigationPolicy.h"
|
| #include "webkit/api/public/WebNavigationType.h"
|
| +#include "webkit/api/public/WebWidgetClient.h"
|
| #include "webkit/glue/context_menu.h"
|
| -#include "webkit/glue/webwidget_delegate.h"
|
|
|
| namespace webkit_glue {
|
| class WebMediaPlayerDelegate;
|
| @@ -51,13 +52,13 @@
|
| class WebMediaPlayerClient;
|
| class WebURLRequest;
|
| class WebURLResponse;
|
| +class WebWidget;
|
| struct WebPoint;
|
| struct WebPopupMenuInfo;
|
| struct WebRect;
|
| struct WebURLError;
|
| }
|
|
|
| -struct WebPreferences;
|
| class FilePath;
|
| class SkBitmap;
|
| class WebDevToolsAgentDelegate;
|
| @@ -65,7 +66,8 @@
|
| class WebMediaPlayerDelegate;
|
| class WebPluginDelegate;
|
| class WebView;
|
| -class WebWidget;
|
| +struct WebPluginGeometry;
|
| +struct WebPreferences;
|
|
|
| enum NavigationGesture {
|
| NavigationGestureUser, // User initiated navigation/load. This is not
|
| @@ -96,8 +98,8 @@
|
|
|
|
|
| // Inheritance here is somewhat weird, but since a WebView is a WebWidget,
|
| -// it makes sense that a WebViewDelegate is a WebWidgetDelegate.
|
| -class WebViewDelegate : virtual public WebWidgetDelegate {
|
| +// it makes sense that a WebViewDelegate is a WebWidgetClient.
|
| +class WebViewDelegate : virtual public WebKit::WebWidgetClient {
|
| public:
|
| // WebView additions -------------------------------------------------------
|
|
|
| @@ -116,13 +118,15 @@
|
|
|
| // This method is called to create a new WebWidget to act as a popup
|
| // (like a drop-down menu).
|
| - virtual WebWidget* CreatePopupWidget(WebView* webview, bool activatable) {
|
| + virtual WebKit::WebWidget* CreatePopupWidget(
|
| + WebView* webview,
|
| + bool activatable) {
|
| return NULL;
|
| }
|
|
|
| // Like CreatePopupWidget, except the actual widget is rendered by the
|
| // embedder using the supplied info.
|
| - virtual WebWidget* CreatePopupWidgetWithInfo(
|
| + virtual WebKit::WebWidget* CreatePopupWidgetWithInfo(
|
| WebView* webview,
|
| const WebKit::WebPopupMenuInfo& info) {
|
| return NULL;
|
| @@ -164,7 +168,7 @@
|
| // This method is called to open a URL in the specified manner.
|
| virtual void OpenURL(WebView* webview, const GURL& url,
|
| const GURL& referrer,
|
| - WindowOpenDisposition disposition) {
|
| + WebKit::WebNavigationPolicy policy) {
|
| }
|
|
|
| // Notifies how many matches have been found so far, for a given request_id.
|
| @@ -197,6 +201,12 @@
|
| virtual void FocusAccessibilityObject(WebCore::AccessibilityObject* acc_obj) {
|
| }
|
|
|
| + // Keeps track of the necessary window move for a plugin window that resulted
|
| + // from a scroll operation. That way, all plugin windows can be moved at the
|
| + // same time as each other and the page.
|
| + virtual void DidMovePlugin(const WebPluginGeometry& move) {
|
| + }
|
| +
|
| // FrameLoaderClient -------------------------------------------------------
|
|
|
| virtual bool CanAcceptLoadDrops() const {
|
| @@ -248,20 +258,20 @@
|
| // proposed navigation. It will be called before loading starts, and
|
| // on every redirect.
|
| //
|
| - // disposition specifies what should normally happen for this
|
| + // default_policy specifies what should normally happen for this
|
| // navigation (open in current tab, start a new tab, start a new
|
| - // window, etc). This method can return an altered disposition, and
|
| + // window, etc). This method can return an altered policy, and
|
| // take any additional separate action it wants to.
|
| //
|
| // is_redirect is true if this is a redirect rather than user action.
|
| - virtual WindowOpenDisposition DispositionForNavigationAction(
|
| + virtual WebKit::WebNavigationPolicy PolicyForNavigationAction(
|
| WebView* webview,
|
| WebFrame* frame,
|
| const WebKit::WebURLRequest& request,
|
| WebKit::WebNavigationType type,
|
| - WindowOpenDisposition disposition,
|
| + WebKit::WebNavigationPolicy default_policy,
|
| bool is_redirect) {
|
| - return disposition;
|
| + return default_policy;
|
| }
|
|
|
| // FrameLoadDelegate -------------------------------------------------------
|
| @@ -525,8 +535,8 @@
|
| const std::wstring& value) {
|
| }
|
|
|
| - virtual void DidContentsSizeChange(WebWidget* webwidget, int new_width,
|
| - int new_height) {
|
| + virtual void DidContentsSizeChange(WebKit::WebWidget* webwidget,
|
| + int new_width, int new_height) {
|
| }
|
|
|
| // UIDelegate --------------------------------------------------------------
|
|
|