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

Side by Side Diff: content/renderer/renderer_webcolorchooser_impl.h

Issue 11232014: Move a bunch of code in content\renderer to the content namespace. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix mac Created 8 years, 2 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
OLDNEW
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_RENDERER_WEBCOLORCHOOSER_IMPL_H_ 5 #ifndef CONTENT_RENDERER_RENDERER_WEBCOLORCHOOSER_IMPL_H_
6 #define CONTENT_RENDERER_RENDERER_WEBCOLORCHOOSER_IMPL_H_ 6 #define CONTENT_RENDERER_RENDERER_WEBCOLORCHOOSER_IMPL_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "content/public/renderer/render_view_observer.h" 9 #include "content/public/renderer/render_view_observer.h"
10 #include "third_party/WebKit/Source/WebKit/chromium/public/WebColorChooser.h" 10 #include "third_party/WebKit/Source/WebKit/chromium/public/WebColorChooser.h"
11 #include "third_party/WebKit/Source/WebKit/chromium/public/WebColorChooserClient .h" 11 #include "third_party/WebKit/Source/WebKit/chromium/public/WebColorChooserClient .h"
12 #include "third_party/skia/include/core/SkColor.h" 12 #include "third_party/skia/include/core/SkColor.h"
13 13
14 namespace WebKit { 14 namespace WebKit {
15 class WebFrame; 15 class WebFrame;
16 } 16 }
17 17
18 namespace content {
18 class RenderViewImpl; 19 class RenderViewImpl;
19 20
20 class RendererWebColorChooserImpl : public WebKit::WebColorChooser, 21 class RendererWebColorChooserImpl : public WebKit::WebColorChooser,
21 public content::RenderViewObserver { 22 public RenderViewObserver {
22 public: 23 public:
23 explicit RendererWebColorChooserImpl(RenderViewImpl* sender, 24 explicit RendererWebColorChooserImpl(RenderViewImpl* sender,
24 WebKit::WebColorChooserClient*); 25 WebKit::WebColorChooserClient*);
25 virtual ~RendererWebColorChooserImpl(); 26 virtual ~RendererWebColorChooserImpl();
26 27
27 virtual void setSelectedColor(const WebKit::WebColor); 28 virtual void setSelectedColor(const WebKit::WebColor);
28 virtual void endChooser(); 29 virtual void endChooser();
29 30
30 void Open(SkColor initial_color); 31 void Open(SkColor initial_color);
31 32
32 WebKit::WebColorChooserClient* client() { return client_; } 33 WebKit::WebColorChooserClient* client() { return client_; }
33 34
34 private: 35 private:
35 // RenderViewObserver implementation. 36 // RenderViewObserver implementation.
36 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE; 37 virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
37 38
38 void OnDidChooseColorResponse(int color_chooser_id, SkColor color); 39 void OnDidChooseColorResponse(int color_chooser_id, SkColor color);
39 void OnDidEndColorChooser(int color_chooser_id); 40 void OnDidEndColorChooser(int color_chooser_id);
40 41
41 int identifier_; 42 int identifier_;
42 WebKit::WebColorChooserClient* client_; 43 WebKit::WebColorChooserClient* client_;
43 44
44 DISALLOW_COPY_AND_ASSIGN(RendererWebColorChooserImpl); 45 DISALLOW_COPY_AND_ASSIGN(RendererWebColorChooserImpl);
45 }; 46 };
46 47
48 } // namespace content
49
47 #endif // CONTENT_RENDERER_RENDERER_WEBCOLORCHOOSER_IMPL_H_ 50 #endif // CONTENT_RENDERER_RENDERER_WEBCOLORCHOOSER_IMPL_H_
OLDNEW
« no previous file with comments | « content/renderer/renderer_webapplicationcachehost_impl.cc ('k') | content/renderer/renderer_webcolorchooser_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698