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

Side by Side Diff: chrome/browser/ui/webui/local_discovery/local_discovery_ui_handler.cc

Issue 502343002: Add account_id to signin manager notifications. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@isauth
Patch Set: Fix android trybots 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/local_discovery/local_discovery_ui_handler.h" 5 #include "chrome/browser/ui/webui/local_discovery/local_discovery_ui_handler.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 462 matching lines...) Expand 10 before | Expand all | Expand 10 after
473 ++succeded_list_count_; 473 ++succeded_list_count_;
474 CheckListingDone(); 474 CheckListingDone();
475 } 475 }
476 476
477 void LocalDiscoveryUIHandler::OnDeviceListUnavailable() { 477 void LocalDiscoveryUIHandler::OnDeviceListUnavailable() {
478 ++failed_list_count_; 478 ++failed_list_count_;
479 CheckListingDone(); 479 CheckListingDone();
480 } 480 }
481 481
482 void LocalDiscoveryUIHandler::GoogleSigninSucceeded( 482 void LocalDiscoveryUIHandler::GoogleSigninSucceeded(
483 const std::string& account_id,
483 const std::string& username, 484 const std::string& username,
484 const std::string& password) { 485 const std::string& password) {
485 CheckUserLoggedIn(); 486 CheckUserLoggedIn();
486 } 487 }
487 488
488 void LocalDiscoveryUIHandler::GoogleSignedOut(const std::string& username) { 489 void LocalDiscoveryUIHandler::GoogleSignedOut(const std::string& account_id,
490 const std::string& username) {
489 CheckUserLoggedIn(); 491 CheckUserLoggedIn();
490 } 492 }
491 493
492 void LocalDiscoveryUIHandler::SendRegisterError() { 494 void LocalDiscoveryUIHandler::SendRegisterError() {
493 web_ui()->CallJavascriptFunction("local_discovery.onRegistrationFailed"); 495 web_ui()->CallJavascriptFunction("local_discovery.onRegistrationFailed");
494 } 496 }
495 497
496 void LocalDiscoveryUIHandler::SendRegisterDone( 498 void LocalDiscoveryUIHandler::SendRegisterDone(
497 const std::string& service_name) { 499 const std::string& service_name) {
498 // HACK(noamsml): Generate network traffic so the Windows firewall doesn't 500 // HACK(noamsml): Generate network traffic so the Windows firewall doesn't
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after
781 scoped_ptr<base::Value> null_value(base::Value::CreateNullValue()); 783 scoped_ptr<base::Value> null_value(base::Value::CreateNullValue());
782 784
783 web_ui()->CallJavascriptFunction( 785 web_ui()->CallJavascriptFunction(
784 "local_discovery.onUnregisteredDeviceUpdate", service_key, *null_value); 786 "local_discovery.onUnregisteredDeviceUpdate", service_key, *null_value);
785 } 787 }
786 } 788 }
787 789
788 #endif // ENABLE_WIFI_BOOTSTRAPPING 790 #endif // ENABLE_WIFI_BOOTSTRAPPING
789 791
790 } // namespace local_discovery 792 } // namespace local_discovery
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698