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

Side by Side Diff: chrome/renderer/pepper_widget.h

Issue 3032024: Add undeclared virtual destructors part 2... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/installer/util/html_dialog.h ('k') | chrome/renderer/render_view_visitor.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 CHROME_RENDERER_PEPPER_WIDGET_H_ 5 #ifndef CHROME_RENDERER_PEPPER_WIDGET_H_
6 #define CHROME_RENDERER_PEPPER_WIDGET_H_ 6 #define CHROME_RENDERER_PEPPER_WIDGET_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "third_party/npapi/bindings/npapi_extensions.h" 9 #include "third_party/npapi/bindings/npapi_extensions.h"
10 10
11 class Graphics2DDeviceContext; 11 class Graphics2DDeviceContext;
12 12
13 // Every class that implements a Pepper widget derives from this. 13 // Every class that implements a Pepper widget derives from this.
14 class PepperWidget { 14 class PepperWidget {
15 public: 15 public:
16 static NPWidgetExtensions* GetWidgetExtensions(); 16 static NPWidgetExtensions* GetWidgetExtensions();
17 17
18 PepperWidget(); 18 PepperWidget();
19 void Init(NPP instance, int id); 19 void Init(NPP instance, int id);
20 20
21 // Called as a result of the corresponding Pepper functions. 21 // Called as a result of the corresponding Pepper functions.
22 virtual void Destroy() = 0; 22 virtual void Destroy() = 0;
23 virtual void Paint(Graphics2DDeviceContext* context, const NPRect& dirty) = 0; 23 virtual void Paint(Graphics2DDeviceContext* context, const NPRect& dirty) = 0;
24 virtual bool HandleEvent(const NPPepperEvent& event) = 0; 24 virtual bool HandleEvent(const NPPepperEvent& event) = 0;
25 virtual void GetProperty(NPWidgetProperty property, void* value) = 0; 25 virtual void GetProperty(NPWidgetProperty property, void* value) = 0;
26 virtual void SetProperty(NPWidgetProperty property, void* value) = 0; 26 virtual void SetProperty(NPWidgetProperty property, void* value) = 0;
27 27
28 protected: 28 protected:
29 ~PepperWidget(); 29 virtual ~PepperWidget();
30 30
31 // Tells the plugin that a property changed. 31 // Tells the plugin that a property changed.
32 void WidgetPropertyChanged(NPWidgetProperty property); 32 void WidgetPropertyChanged(NPWidgetProperty property);
33 33
34 private: 34 private:
35 NPP instance_; 35 NPP instance_;
36 int id_; 36 int id_;
37 37
38 DISALLOW_COPY_AND_ASSIGN(PepperWidget); 38 DISALLOW_COPY_AND_ASSIGN(PepperWidget);
39 }; 39 };
40 40
41 #endif // CHROME_RENDERER_PEPPER_WIDGET_H_ 41 #endif // CHROME_RENDERER_PEPPER_WIDGET_H_
OLDNEW
« no previous file with comments | « chrome/installer/util/html_dialog.h ('k') | chrome/renderer/render_view_visitor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698