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

Side by Side Diff: chrome/browser/ui/webui/chromeos/login/eula_screen_handler.h

Issue 14208014: Simplify adding callbacks. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix. Created 7 years, 8 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 CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_EULA_SCREEN_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_EULA_SCREEN_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_EULA_SCREEN_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_EULA_SCREEN_HANDLER_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "chrome/browser/chromeos/login/screens/eula_screen_actor.h" 10 #include "chrome/browser/chromeos/login/screens/eula_screen_actor.h"
11 #include "chrome/browser/chromeos/login/tpm_password_fetcher.h" 11 #include "chrome/browser/chromeos/login/tpm_password_fetcher.h"
12 #include "chrome/browser/ui/webui/chromeos/login/base_screen_handler.h" 12 #include "chrome/browser/ui/webui/chromeos/login/base_screen_handler.h"
13 #include "content/public/browser/web_ui.h" 13 #include "content/public/browser/web_ui.h"
14 14
15 namespace base { 15 namespace base {
16 class DictionaryValue; 16 class DictionaryValue;
17 class ListValue;
18 } 17 }
19 18
20 namespace chromeos { 19 namespace chromeos {
21 20
22 class HelpAppLauncher; 21 class HelpAppLauncher;
23 22
24 // WebUI implementation of EulaScreenActor. It is used to interact 23 // WebUI implementation of EulaScreenActor. It is used to interact
25 // with the eula part of the JS page. 24 // with the eula part of the JS page.
26 class EulaScreenHandler : public EulaScreenActor, 25 class EulaScreenHandler : public EulaScreenActor,
27 public BaseScreenHandler, 26 public BaseScreenHandler,
(...skipping 12 matching lines...) Expand all
40 // BaseScreenHandler implementation: 39 // BaseScreenHandler implementation:
41 virtual void DeclareLocalizedValues(LocalizedValuesBuilder* builder) OVERRIDE; 40 virtual void DeclareLocalizedValues(LocalizedValuesBuilder* builder) OVERRIDE;
42 virtual void GetAdditionalParameters(base::DictionaryValue* dict) OVERRIDE; 41 virtual void GetAdditionalParameters(base::DictionaryValue* dict) OVERRIDE;
43 virtual void Initialize() OVERRIDE; 42 virtual void Initialize() OVERRIDE;
44 43
45 // WebUIMessageHandler implementation: 44 // WebUIMessageHandler implementation:
46 virtual void RegisterMessages() OVERRIDE; 45 virtual void RegisterMessages() OVERRIDE;
47 46
48 private: 47 private:
49 // JS messages handlers. 48 // JS messages handlers.
50 void HandleOnExit(const base::ListValue* args); 49 void HandleOnExit(bool accepted, bool usager_stats_enabled);
51 void HandleOnLearnMore(const base::ListValue* args); 50 void HandleOnLearnMore();
52 void HandleOnInstallationSettingsPopupOpened(const base::ListValue* args); 51 void HandleOnInstallationSettingsPopupOpened();
53 52
54 Delegate* delegate_; 53 Delegate* delegate_;
55 54
56 // Help application used for help dialogs. 55 // Help application used for help dialogs.
57 scoped_refptr<HelpAppLauncher> help_app_; 56 scoped_refptr<HelpAppLauncher> help_app_;
58 57
59 // Keeps whether screen should be shown right after initialization. 58 // Keeps whether screen should be shown right after initialization.
60 bool show_on_init_; 59 bool show_on_init_;
61 60
62 DISALLOW_COPY_AND_ASSIGN(EulaScreenHandler); 61 DISALLOW_COPY_AND_ASSIGN(EulaScreenHandler);
63 }; 62 };
64 63
65 } // namespace chromeos 64 } // namespace chromeos
66 65
67 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_EULA_SCREEN_HANDLER_H_ 66 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_EULA_SCREEN_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698