OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_BROWSER_UI_VIEWS_COLOR_CHOOSER_AURA_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_COLOR_CHOOSER_AURA_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_COLOR_CHOOSER_AURA_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_COLOR_CHOOSER_AURA_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "content/public/browser/color_chooser.h" | 10 #include "content/public/browser/color_chooser.h" |
(...skipping 13 matching lines...) Expand all Loading... |
24 class ColorChooserAura : public content::ColorChooser, | 24 class ColorChooserAura : public content::ColorChooser, |
25 public views::ColorChooserListener { | 25 public views::ColorChooserListener { |
26 public: | 26 public: |
27 static ColorChooserAura* Open(content::WebContents* web_contents, | 27 static ColorChooserAura* Open(content::WebContents* web_contents, |
28 SkColor initial_color); | 28 SkColor initial_color); |
29 | 29 |
30 private: | 30 private: |
31 ColorChooserAura(content::WebContents* web_contents, SkColor initial_color); | 31 ColorChooserAura(content::WebContents* web_contents, SkColor initial_color); |
32 | 32 |
33 // content::ColorChooser overrides: | 33 // content::ColorChooser overrides: |
34 virtual void End() OVERRIDE; | 34 virtual void End() override; |
35 virtual void SetSelectedColor(SkColor color) OVERRIDE; | 35 virtual void SetSelectedColor(SkColor color) override; |
36 | 36 |
37 // views::ColorChooserListener overrides: | 37 // views::ColorChooserListener overrides: |
38 virtual void OnColorChosen(SkColor color) OVERRIDE; | 38 virtual void OnColorChosen(SkColor color) override; |
39 virtual void OnColorChooserDialogClosed() OVERRIDE; | 39 virtual void OnColorChooserDialogClosed() override; |
40 | 40 |
41 void DidEndColorChooser(); | 41 void DidEndColorChooser(); |
42 | 42 |
43 // The actual view of the color chooser. No ownership because its parent | 43 // The actual view of the color chooser. No ownership because its parent |
44 // view will take care of its lifetime. | 44 // view will take care of its lifetime. |
45 views::ColorChooserView* view_; | 45 views::ColorChooserView* view_; |
46 | 46 |
47 // The widget for the color chooser. No ownership because it's released | 47 // The widget for the color chooser. No ownership because it's released |
48 // automatically when closed. | 48 // automatically when closed. |
49 views::Widget* widget_; | 49 views::Widget* widget_; |
50 | 50 |
51 // The web contents invoking the color chooser. No ownership because it will | 51 // The web contents invoking the color chooser. No ownership because it will |
52 // outlive this class. | 52 // outlive this class. |
53 content::WebContents* web_contents_; | 53 content::WebContents* web_contents_; |
54 | 54 |
55 DISALLOW_COPY_AND_ASSIGN(ColorChooserAura); | 55 DISALLOW_COPY_AND_ASSIGN(ColorChooserAura); |
56 }; | 56 }; |
57 | 57 |
58 #endif // CHROME_BROWSER_UI_VIEWS_COLOR_CHOOSER_AURA_H_ | 58 #endif // CHROME_BROWSER_UI_VIEWS_COLOR_CHOOSER_AURA_H_ |
OLD | NEW |