Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(125)

Unified Diff: webkit/glue/webview_delegate.h

Issue 149620: Use WebWidget from the WebKit API. This change also makes... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/glue/webview.h ('k') | webkit/glue/webview_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 --------------------------------------------------------------
« no previous file with comments | « webkit/glue/webview.h ('k') | webkit/glue/webview_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698