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

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

Issue 491263002: UI flow rework for device reset options. Reset made available from gaia screen. Tests adapted. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: ShowAndCancelTest fixed. Created 6 years, 3 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_RESET_SCREEN_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_RESET_SCREEN_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_RESET_SCREEN_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_RESET_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 "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 const UpdateEngineClient::Status& status) OVERRIDE; 44 const UpdateEngineClient::Status& status) OVERRIDE;
45 45
46 void OnRollbackCheck(bool can_rollback); 46 void OnRollbackCheck(bool can_rollback);
47 47
48 // Registers Local State preferences. 48 // Registers Local State preferences.
49 static void RegisterPrefs(PrefRegistrySimple* registry); 49 static void RegisterPrefs(PrefRegistrySimple* registry);
50 50
51 private: 51 private:
52 // JS messages handlers. 52 // JS messages handlers.
53 void HandleOnCancel(); 53 void HandleOnCancel();
54 void HandleOnRestart(bool should_rollback); 54 void HandleOnRestart();
55 void HandleOnPowerwash(bool rollback_checked); 55 void HandleOnPowerwash(bool rollback_checked);
56 void HandleOnLearnMore(); 56 void HandleOnLearnMore();
57 void HandleOnShowRollback();
58 void HandleOnHideRollback();
59 void HandleOnShowConfirm();
57 60
58 void ChooseAndApplyShowScenario(); 61 void ChooseAndApplyShowScenario();
59 void ShowWithParams(); 62 void ShowWithParams();
60 63
61 Delegate* delegate_; 64 Delegate* delegate_;
62 65
63 // Help application used for help dialogs. 66 // Help application used for help dialogs.
64 scoped_refptr<HelpAppLauncher> help_app_; 67 scoped_refptr<HelpAppLauncher> help_app_;
65 68
66 // Keeps whether screen should be shown right after initialization. 69 // Keeps whether screen should be shown right after initialization.
67 bool show_on_init_; 70 bool show_on_init_;
68 71
69 // Keeps whether restart is required before reset. 72 // Keeps whether restart is required before reset.
70 // False if first exec after boot. 73 // False if first exec after boot.
71 bool restart_required_; 74 bool restart_required_;
72 75
73 // Keeps whether previous reboot was requested from reset screen. Makes sense 76 // Keeps whether previous reboot was requested from reset screen. Makes sense
74 // for first exec after boot situation. 77 // for first exec after boot situation.
75 bool reboot_was_requested_; 78 bool reboot_was_requested_;
76 79
77 // Keeps whether rollback option is available fo. 80 // Keeps whether rollback option is available.
78 bool rollback_available_; 81 bool rollback_available_;
79 82
80 // Whether rollback is initiated. 83 // Keeps whether rollback option is active at the screen.
84 bool rollback_checked_;
85
86 // Whether rollback is initiated. Prevents screen-hide.
81 bool preparing_for_rollback_; 87 bool preparing_for_rollback_;
82 88
83 base::WeakPtrFactory<ResetScreenHandler> weak_ptr_factory_; 89 base::WeakPtrFactory<ResetScreenHandler> weak_ptr_factory_;
84 90
85 DISALLOW_COPY_AND_ASSIGN(ResetScreenHandler); 91 DISALLOW_COPY_AND_ASSIGN(ResetScreenHandler);
86 }; 92 };
87 93
88 } // namespace chromeos 94 } // namespace chromeos
89 95
90 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_RESET_SCREEN_HANDLER_H_ 96 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_RESET_SCREEN_HANDLER_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/chromeos/login/oobe_ui.cc ('k') | chrome/browser/ui/webui/chromeos/login/reset_screen_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698