OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ | 5 #ifndef CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ |
6 #define CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ | 6 #define CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ |
7 | 7 |
8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPlugin.h" | 8 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPlugin.h" |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 18 matching lines...) Expand all Loading... |
29 class BrowserPluginManager; | 29 class BrowserPluginManager; |
30 class MockBrowserPlugin; | 30 class MockBrowserPlugin; |
31 | 31 |
32 class CONTENT_EXPORT BrowserPlugin : | 32 class CONTENT_EXPORT BrowserPlugin : |
33 NON_EXPORTED_BASE(public WebKit::WebPlugin) { | 33 NON_EXPORTED_BASE(public WebKit::WebPlugin) { |
34 public: | 34 public: |
35 RenderViewImpl* render_view() const { return render_view_.get(); } | 35 RenderViewImpl* render_view() const { return render_view_.get(); } |
36 // Called only by tests to clean up before we blow away the MockRenderProcess. | 36 // Called only by tests to clean up before we blow away the MockRenderProcess. |
37 void Cleanup(); | 37 void Cleanup(); |
38 | 38 |
| 39 // Update Browser Plugin's DOM Node attribute |attribute_name| with the value |
| 40 // |attribute_value|. |
| 41 void UpdateDOMAttribute(const std::string& attribute_name, |
| 42 const std::string& attribute_value); |
| 43 |
39 // Get the src attribute value of the BrowserPlugin instance. | 44 // Get the src attribute value of the BrowserPlugin instance. |
40 std::string src_attribute() const { return src_; } | 45 std::string src_attribute() const { return src_; } |
41 // Set the src attribute value of the BrowserPlugin instance. | 46 // Set the src attribute value of the BrowserPlugin instance. |
42 bool SetSrcAttribute(const std::string& src, std::string* error_message); | 47 bool SetSrcAttribute(const std::string& src, std::string* error_message); |
43 // Get the autosize attribute value. | 48 // Get the autosize attribute value. |
44 bool auto_size_attribute() const { return auto_size_; } | 49 bool auto_size_attribute() const { return auto_size_; } |
45 // Sets the autosize attribute value. | 50 // Sets the autosize attribute value. |
46 void SetAutoSizeAttribute(bool auto_size); | 51 void SetAutoSizeAttribute(bool auto_size); |
47 // Get the maxheight attribute value. | 52 // Get the maxheight attribute value. |
48 int max_height_attribute() const { return max_height_; } | 53 int max_height_attribute() const { return max_height_; } |
(...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
328 // the changes are not always obvious. For example, there is a maximum | 333 // the changes are not always obvious. For example, there is a maximum |
329 // number of entries and earlier ones will automatically be pruned. | 334 // number of entries and earlier ones will automatically be pruned. |
330 int current_nav_entry_index_; | 335 int current_nav_entry_index_; |
331 int nav_entry_count_; | 336 int nav_entry_count_; |
332 DISALLOW_COPY_AND_ASSIGN(BrowserPlugin); | 337 DISALLOW_COPY_AND_ASSIGN(BrowserPlugin); |
333 }; | 338 }; |
334 | 339 |
335 } // namespace content | 340 } // namespace content |
336 | 341 |
337 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ | 342 #endif // CONTENT_RENDERER_BROWSER_PLUGIN_BROWSER_PLUGIN_H_ |
OLD | NEW |