OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_WEBUI_OPTIONS_OPTIONS_UI_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_OPTIONS_OPTIONS_UI_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_OPTIONS_UI_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_OPTIONS_OPTIONS_UI_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 | 65 |
66 private: | 66 private: |
67 DISALLOW_COPY_AND_ASSIGN(OptionsPageUIHandler); | 67 DISALLOW_COPY_AND_ASSIGN(OptionsPageUIHandler); |
68 }; | 68 }; |
69 | 69 |
70 // An interface for common operations that a host of OptionsPageUIHandlers | 70 // An interface for common operations that a host of OptionsPageUIHandlers |
71 // should provide. | 71 // should provide. |
72 class OptionsPageUIHandlerHost { | 72 class OptionsPageUIHandlerHost { |
73 public: | 73 public: |
74 virtual void InitializeHandlers() = 0; | 74 virtual void InitializeHandlers() = 0; |
| 75 |
| 76 protected: |
| 77 virtual ~OptionsPageUIHandlerHost() {} |
75 }; | 78 }; |
76 | 79 |
77 // The WebUI for chrome:settings. | 80 // The WebUI for chrome:settings. |
78 class OptionsUI : public ChromeWebUI, | 81 class OptionsUI : public ChromeWebUI, |
79 public OptionsPageUIHandlerHost { | 82 public OptionsPageUIHandlerHost { |
80 public: | 83 public: |
81 explicit OptionsUI(TabContents* contents); | 84 explicit OptionsUI(TabContents* contents); |
82 virtual ~OptionsUI(); | 85 virtual ~OptionsUI(); |
83 | 86 |
84 static RefCountedMemory* GetFaviconResourceBytes(); | 87 static RefCountedMemory* GetFaviconResourceBytes(); |
(...skipping 14 matching lines...) Expand all Loading... |
99 // Sets the WebUI CommandLineString property with arguments passed while | 102 // Sets the WebUI CommandLineString property with arguments passed while |
100 // launching chrome. | 103 // launching chrome. |
101 void SetCommandLineString(RenderViewHost* render_view_host); | 104 void SetCommandLineString(RenderViewHost* render_view_host); |
102 | 105 |
103 bool initialized_handlers_; | 106 bool initialized_handlers_; |
104 | 107 |
105 DISALLOW_COPY_AND_ASSIGN(OptionsUI); | 108 DISALLOW_COPY_AND_ASSIGN(OptionsUI); |
106 }; | 109 }; |
107 | 110 |
108 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_OPTIONS_UI_H_ | 111 #endif // CHROME_BROWSER_UI_WEBUI_OPTIONS_OPTIONS_UI_H_ |
OLD | NEW |