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

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

Issue 2820203002: cros Revert DCHECKs added in crbug.com/699798. (Closed)
Patch Set: Created 3 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
« no previous file with comments | « no previous file | chrome/browser/ui/webui/chromeos/login/signin_screen_handler.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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_BASE_WEBUI_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_BASE_WEBUI_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_BASE_WEBUI_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_BASE_WEBUI_HANDLER_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 207 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 OobeScreen GetCurrentScreen() const; 218 OobeScreen GetCurrentScreen() const;
219 219
220 // Whether page is ready. 220 // Whether page is ready.
221 bool page_is_ready() const { return page_is_ready_; } 221 bool page_is_ready() const { return page_is_ready_; }
222 222
223 // Returns the window which shows us. 223 // Returns the window which shows us.
224 virtual gfx::NativeWindow GetNativeWindow(); 224 virtual gfx::NativeWindow GetNativeWindow();
225 225
226 void SetBaseScreen(BaseScreen* base_screen); 226 void SetBaseScreen(BaseScreen* base_screen);
227 227
228 // Returns true if JS side has sent a screenStateInitialize event.
229 // TODO(jdufault): Remove after resolving crbug.com/699798
230 bool is_js_initialized_and_ready() const {
231 return js_calls_container_->is_initialized();
232 }
233
234 private: 228 private:
235 // Calls Javascript method. 229 // Calls Javascript method.
236 // 230 //
237 // Note that the Args template parameter pack should consist of types 231 // Note that the Args template parameter pack should consist of types
238 // convertible to base::Value. 232 // convertible to base::Value.
239 template <typename... Args> 233 template <typename... Args>
240 void ExecuteDeferredJSCall(const std::string& function_name, 234 void ExecuteDeferredJSCall(const std::string& function_name,
241 std::unique_ptr<Args>... args) { 235 std::unique_ptr<Args>... args) {
242 CallJS(function_name, *args...); 236 CallJS(function_name, *args...);
243 } 237 }
(...skipping 27 matching lines...) Expand all
271 base::DictionaryValue pending_context_changes_; 265 base::DictionaryValue pending_context_changes_;
272 266
273 JSCallsContainer* js_calls_container_ = nullptr; // non-owning pointers. 267 JSCallsContainer* js_calls_container_ = nullptr; // non-owning pointers.
274 268
275 DISALLOW_COPY_AND_ASSIGN(BaseWebUIHandler); 269 DISALLOW_COPY_AND_ASSIGN(BaseWebUIHandler);
276 }; 270 };
277 271
278 } // namespace chromeos 272 } // namespace chromeos
279 273
280 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_BASE_WEBUI_HANDLER_H_ 274 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_BASE_WEBUI_HANDLER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/webui/chromeos/login/signin_screen_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698