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 CHROME_BROWSER_UI_WEBUI_SIGNIN_INTERNALS_UI_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_SIGNIN_INTERNALS_UI_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_SIGNIN_INTERNALS_UI_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_SIGNIN_INTERNALS_UI_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 "base/memory/scoped_ptr.h" | |
11 #include "base/values.h" | 10 #include "base/values.h" |
12 #include "components/signin/core/browser/about_signin_internals.h" | 11 #include "components/signin/core/browser/about_signin_internals.h" |
13 #include "content/public/browser/web_ui_controller.h" | 12 #include "content/public/browser/web_ui_controller.h" |
14 | 13 |
15 // The implementation for the chrome://signin-internals page. | 14 // The implementation for the chrome://signin-internals page. |
16 class SignInInternalsUI : public content::WebUIController, | 15 class SignInInternalsUI : public content::WebUIController, |
17 public AboutSigninInternals::Observer { | 16 public AboutSigninInternals::Observer { |
18 public: | 17 public: |
19 explicit SignInInternalsUI(content::WebUI* web_ui); | 18 explicit SignInInternalsUI(content::WebUI* web_ui); |
20 virtual ~SignInInternalsUI(); | 19 virtual ~SignInInternalsUI(); |
21 | 20 |
22 | 21 |
23 // content::WebUIController implementation. | 22 // content::WebUIController implementation. |
24 virtual bool OverrideHandleWebUIMessage(const GURL& source_url, | 23 virtual bool OverrideHandleWebUIMessage(const GURL& source_url, |
25 const std::string& name, | 24 const std::string& name, |
26 const base::ListValue& args) OVERRIDE; | 25 const base::ListValue& args) OVERRIDE; |
27 | 26 |
28 // AboutSigninInternals::Observer::OnSigninStateChanged implementation. | 27 // AboutSigninInternals::Observer::OnSigninStateChanged implementation. |
29 virtual void OnSigninStateChanged( | 28 virtual void OnSigninStateChanged(const base::DictionaryValue* info) OVERRIDE; |
30 scoped_ptr<base::DictionaryValue> info) OVERRIDE; | |
31 | 29 |
32 // Notification that the cookie accounts are ready to be displayed. | 30 // Notification that the cookie accounts are ready to be displayed. |
33 virtual void OnCookieAccountsFetched( | 31 virtual void OnCookieAccountsFetched( |
34 scoped_ptr<base::DictionaryValue> info) OVERRIDE; | 32 const base::DictionaryValue* info) OVERRIDE; |
35 | 33 |
36 private: | 34 private: |
37 DISALLOW_COPY_AND_ASSIGN(SignInInternalsUI); | 35 DISALLOW_COPY_AND_ASSIGN(SignInInternalsUI); |
38 }; | 36 }; |
39 | 37 |
40 #endif // CHROME_BROWSER_UI_WEBUI_SIGNIN_INTERNALS_UI_H_ | 38 #endif // CHROME_BROWSER_UI_WEBUI_SIGNIN_INTERNALS_UI_H_ |
OLD | NEW |