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

Unified Diff: webkit/glue/webplugin_impl.h

Issue 1612: Implement "iframe shim" behavior for windowed plugins.... (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 12 years, 3 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/webplugin_delegate.h ('k') | webkit/glue/webplugin_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/webplugin_impl.h
===================================================================
--- webkit/glue/webplugin_impl.h (revision 2783)
+++ webkit/glue/webplugin_impl.h (working copy)
@@ -15,6 +15,7 @@
#include "ResourceHandleClient.h"
#include "ResourceRequest.h"
#include "Widget.h"
+#include "Vector.h"
#pragma warning(pop)
#include "base/basictypes.h"
@@ -64,6 +65,13 @@
virtual void attachToWindow();
virtual void detachFromWindow();
+ // Returns window-relative rectangles that should clip this widget.
+ // Use this to implement iframe shim behavior.
+ //
+ // TODO(tulrich): add this method to WebCore/platform/Widget.h so it
+ // can be used by any platform.
+ void windowCutoutRects(WTF::Vector<WebCore::IntRect>* cutouts) const;
+
// These methods are invoked from webkit when it has data to be sent to the
// plugin. The plugin in this case does not initiate a download for the data.
void didReceiveResponse(const WebCore::ResourceResponse& response);
@@ -176,6 +184,13 @@
virtual WebCore::IntRect windowClipRect() const;
virtual void geometryChanged() const;
+ // Returns window-relative rectangles that should clip this widget.
+ // Use this to implement iframe shim behavior.
+ //
+ // TODO(tulrich): windowCutoutRects() is not in WebCore::Widgets
+ // yet; need to add it.
+ void windowCutoutRects(WTF::Vector<WebCore::IntRect>* rects) const;
+
// Override for when our window changes size or position.
// Used to notify the plugin when the size or position changes.
virtual void setFrameGeometry(const WebCore::IntRect& rect);
@@ -235,7 +250,8 @@
// Calculates the bounds of the plugin widget based on the frame rect passed in.
void CalculateBounds(const WebCore::IntRect& frame_rect,
WebCore::IntRect* window_rect,
- WebCore::IntRect* clip_rect);
+ WebCore::IntRect* clip_rect,
+ std::vector<gfx::Rect>* cutout_rects);
void HandleURLRequest(const char *method,
bool is_javascript_url,
« no previous file with comments | « webkit/glue/webplugin_delegate.h ('k') | webkit/glue/webplugin_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698