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

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

Issue 2865003003: Put OOBE UI on touch display if no keyboard detected (Closed)
Patch Set: Address most (all?) code comments up to #7 Created 3 years, 7 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
OLDNEW
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_CHROMEOS_LOGIN_OOBE_UI_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_OOBE_UI_H_
6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_OOBE_UI_H_ 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_OOBE_UI_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 #include <string> 10 #include <string>
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 class HIDDetectionView; 46 class HIDDetectionView;
47 class HostPairingScreenView; 47 class HostPairingScreenView;
48 class KioskAppMenuHandler; 48 class KioskAppMenuHandler;
49 class KioskAutolaunchScreenView; 49 class KioskAutolaunchScreenView;
50 class KioskEnableScreenView; 50 class KioskEnableScreenView;
51 class LoginScreenContext; 51 class LoginScreenContext;
52 class NativeWindowDelegate; 52 class NativeWindowDelegate;
53 class NetworkDropdownHandler; 53 class NetworkDropdownHandler;
54 class NetworkStateInformer; 54 class NetworkStateInformer;
55 class NetworkView; 55 class NetworkView;
56 class OobeDisplayChooser;
56 class SigninScreenHandler; 57 class SigninScreenHandler;
57 class SigninScreenHandlerDelegate; 58 class SigninScreenHandlerDelegate;
58 class SupervisedUserCreationScreenHandler; 59 class SupervisedUserCreationScreenHandler;
59 class ResetView; 60 class ResetView;
60 class TermsOfServiceScreenView; 61 class TermsOfServiceScreenView;
61 class UserBoardView; 62 class UserBoardView;
62 class UserImageView; 63 class UserImageView;
63 class UpdateView; 64 class UpdateView;
64 class WrongHWIDScreenView; 65 class WrongHWIDScreenView;
65 66
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 } 164 }
164 165
165 NetworkStateInformer* network_state_informer_for_test() const { 166 NetworkStateInformer* network_state_informer_for_test() const {
166 return network_state_informer_.get(); 167 return network_state_informer_.get();
167 } 168 }
168 169
169 // Does ReloadContent() if needed (for example, if material design mode has 170 // Does ReloadContent() if needed (for example, if material design mode has
170 // changed). 171 // changed).
171 void UpdateLocalizedStringsIfNeeded(); 172 void UpdateLocalizedStringsIfNeeded();
172 173
174 // Re-evaluate OOBE display placement taking a new display into consideration.
175 void OnDisplayAdded();
176
173 private: 177 private:
174 // Lookup a view by its statically registered OobeScreen. 178 // Lookup a view by its statically registered OobeScreen.
175 template <typename TView> 179 template <typename TView>
176 TView* GetView() { 180 TView* GetView() {
177 OobeScreen expected_screen = TView::kScreenId; 181 OobeScreen expected_screen = TView::kScreenId;
178 for (BaseScreenHandler* handler : screen_handlers_) { 182 for (BaseScreenHandler* handler : screen_handlers_) {
179 if (expected_screen == handler->oobe_screen()) 183 if (expected_screen == handler->oobe_screen())
180 return static_cast<TView*>(handler); 184 return static_cast<TView*>(handler);
181 } 185 }
182 186
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
234 std::vector<base::Closure> ready_callbacks_; 238 std::vector<base::Closure> ready_callbacks_;
235 239
236 // List of registered observers. 240 // List of registered observers.
237 base::ObserverList<Observer> observer_list_; 241 base::ObserverList<Observer> observer_list_;
238 242
239 // Observer of CrosSettings watching the kRebootOnShutdown policy. 243 // Observer of CrosSettings watching the kRebootOnShutdown policy.
240 std::unique_ptr<ShutdownPolicyHandler> shutdown_policy_handler_; 244 std::unique_ptr<ShutdownPolicyHandler> shutdown_policy_handler_;
241 245
242 std::unique_ptr<ash::ScreenDimmer> screen_dimmer_; 246 std::unique_ptr<ash::ScreenDimmer> screen_dimmer_;
243 247
248 std::unique_ptr<OobeDisplayChooser> oobe_display_chooser_;
jdufault 2017/05/09 18:59:38 Consider using base::Optional, up to you.
249
244 // Store the deferred JS calls before the screen handler instance is 250 // Store the deferred JS calls before the screen handler instance is
245 // initialized. 251 // initialized.
246 std::unique_ptr<JSCallsContainer> js_calls_container; 252 std::unique_ptr<JSCallsContainer> js_calls_container;
247 253
248 DISALLOW_COPY_AND_ASSIGN(OobeUI); 254 DISALLOW_COPY_AND_ASSIGN(OobeUI);
249 }; 255 };
250 256
251 } // namespace chromeos 257 } // namespace chromeos
252 258
253 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_OOBE_UI_H_ 259 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_OOBE_UI_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698