OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "chrome/browser/ui/webui/chromeos/login/controller_pairing_screen_handl
er.h" | 5 #include "chrome/browser/ui/webui/chromeos/login/controller_pairing_screen_handl
er.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/strings/string_util.h" | 8 #include "base/strings/string_util.h" |
9 #include "chrome/browser/chromeos/login/oobe_screen.h" | 9 #include "chrome/browser/chromeos/login/oobe_screen.h" |
10 #include "chrome/grit/generated_resources.h" | 10 #include "chrome/grit/generated_resources.h" |
(...skipping 18 matching lines...) Expand all Loading... |
29 } | 29 } |
30 | 30 |
31 } // namespace | 31 } // namespace |
32 | 32 |
33 ControllerPairingScreenHandler::ControllerPairingScreenHandler() { | 33 ControllerPairingScreenHandler::ControllerPairingScreenHandler() { |
34 set_call_js_prefix(kJsScreenPath); | 34 set_call_js_prefix(kJsScreenPath); |
35 } | 35 } |
36 | 36 |
37 ControllerPairingScreenHandler::~ControllerPairingScreenHandler() { | 37 ControllerPairingScreenHandler::~ControllerPairingScreenHandler() { |
38 if (delegate_) | 38 if (delegate_) |
39 delegate_->OnActorDestroyed(this); | 39 delegate_->OnViewDestroyed(this); |
40 } | 40 } |
41 | 41 |
42 void ControllerPairingScreenHandler::HandleUserActed( | 42 void ControllerPairingScreenHandler::HandleUserActed( |
43 const std::string& action) { | 43 const std::string& action) { |
44 if (!delegate_) | 44 if (!delegate_) |
45 return; | 45 return; |
46 delegate_->OnUserActed(action); | 46 delegate_->OnUserActed(action); |
47 } | 47 } |
48 | 48 |
49 void ControllerPairingScreenHandler::HandleContextChanged( | 49 void ControllerPairingScreenHandler::HandleContextChanged( |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
165 void ControllerPairingScreenHandler::OnContextChanged( | 165 void ControllerPairingScreenHandler::OnContextChanged( |
166 const base::DictionaryValue& diff) { | 166 const base::DictionaryValue& diff) { |
167 CallJS(kMethodContextChanged, diff); | 167 CallJS(kMethodContextChanged, diff); |
168 } | 168 } |
169 | 169 |
170 content::BrowserContext* ControllerPairingScreenHandler::GetBrowserContext() { | 170 content::BrowserContext* ControllerPairingScreenHandler::GetBrowserContext() { |
171 return web_ui()->GetWebContents()->GetBrowserContext(); | 171 return web_ui()->GetWebContents()->GetBrowserContext(); |
172 } | 172 } |
173 | 173 |
174 } // namespace chromeos | 174 } // namespace chromeos |
OLD | NEW |