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

Unified Diff: content/renderer/browser_plugin/browser_plugin.h

Issue 427883002: <webview>: Move autosize from content to chrome (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@remove_frame_url
Patch Set: Initialize variable Created 6 years, 4 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
Index: content/renderer/browser_plugin/browser_plugin.h
diff --git a/content/renderer/browser_plugin/browser_plugin.h b/content/renderer/browser_plugin/browser_plugin.h
index d35b173c80cb15d54f0647fbf282260f74041d16..ee606a1781c5d0d95e3ef046e92f7cf81b43b946 100644
--- a/content/renderer/browser_plugin/browser_plugin.h
+++ b/content/renderer/browser_plugin/browser_plugin.h
@@ -17,7 +17,6 @@
#include "third_party/WebKit/public/web/WebDragStatus.h"
#include "third_party/WebKit/public/web/WebWidget.h"
-struct BrowserPluginHostMsg_AutoSize_Params;
struct BrowserPluginHostMsg_ResizeGuest_Params;
struct BrowserPluginMsg_UpdateRect_Params;
struct FrameMsg_BuffersSwapped_Params;
@@ -58,22 +57,6 @@ class CONTENT_EXPORT BrowserPlugin :
// Parse the allowtransparency attribute and adjust transparency of
// BrowserPlugin accordingly.
void ParseAllowTransparencyAttribute();
- // Get the autosize attribute value.
- bool GetAutoSizeAttribute() const;
- // Parses the autosize attribute value.
- void ParseAutoSizeAttribute();
- // Get the maxheight attribute value.
- int GetMaxHeightAttribute() const;
- // Get the maxwidth attribute value.
- int GetMaxWidthAttribute() const;
- // Get the minheight attribute value.
- int GetMinHeightAttribute() const;
- // Get the minwidth attribute value.
- int GetMinWidthAttribute() const;
- // Parse the minwidth, maxwidth, minheight, and maxheight attribute values.
- void ParseSizeContraintsChanged();
-
- bool InAutoSizeBounds(const gfx::Size& size) const;
// Get the guest's DOMWindow proxy.
NPObject* GetContentWindow() const;
@@ -192,46 +175,24 @@ class CONTENT_EXPORT BrowserPlugin :
int height() const { return plugin_rect_.height(); }
gfx::Size plugin_size() const { return plugin_rect_.size(); }
gfx::Rect plugin_rect() const { return plugin_rect_; }
- // Gets the Max Height value used for auto size.
- int GetAdjustedMaxHeight() const;
- // Gets the Max Width value used for auto size.
- int GetAdjustedMaxWidth() const;
- // Gets the Min Height value used for auto size.
- int GetAdjustedMinHeight() const;
- // Gets the Min Width value used for auto size.
- int GetAdjustedMinWidth() const;
// Virtual to allow for mocking in tests.
virtual float GetDeviceScaleFactor() const;
void ShowSadGraphic();
- // Triggers the event-listeners for |event_name|. Note that the function
- // frees all the values in |props|.
- void TriggerEvent(const std::string& event_name,
- std::map<std::string, base::Value*>* props);
-
// Populates BrowserPluginHostMsg_ResizeGuest_Params with resize state.
void PopulateResizeGuestParameters(
BrowserPluginHostMsg_ResizeGuest_Params* params,
const gfx::Size& view_size,
bool needs_repaint);
- // Populates BrowserPluginHostMsg_AutoSize_Params object with autosize state.
- void PopulateAutoSizeParameters(
- BrowserPluginHostMsg_AutoSize_Params* params, bool auto_size_enabled);
-
- // Populates both AutoSize and ResizeGuest parameters based on the current
+ // Populates ResizeGuest parameters based on the current
// autosize state.
void GetSizeParams(
- BrowserPluginHostMsg_AutoSize_Params* auto_size_params,
BrowserPluginHostMsg_ResizeGuest_Params* resize_guest_params,
bool needs_repaint);
- // Informs the guest of an updated autosize state.
- void UpdateGuestAutoSizeState(bool auto_size_enabled);
-
-
// IPC message handlers.
// Please keep in alphabetical order.
void OnAdvanceFocus(int instance_id, bool reverse);
@@ -271,9 +232,6 @@ class CONTENT_EXPORT BrowserPlugin :
// Bitmap for crashed plugin. Lazily initialized, non-owning pointer.
SkBitmap* sad_guest_;
bool guest_crashed_;
- bool is_auto_size_state_dirty_;
- // Maximum size constraint for autosize.
- gfx::Size max_auto_size_;
int content_window_routing_id_;
bool plugin_focused_;
// Tracks the visibility of the browser plugin regardless of the whole
« no previous file with comments | « content/public/browser/browser_plugin_guest_delegate.h ('k') | content/renderer/browser_plugin/browser_plugin.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698