| OLD | NEW |
| 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 #include "chrome/browser/extensions/api/webstore_private/webstore_private_api.h" | 5 #include "chrome/browser/extensions/api/webstore_private/webstore_private_api.h" |
| 6 | 6 |
| 7 #include "base/bind_helpers.h" | 7 #include "base/bind_helpers.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/lazy_instance.h" | 9 #include "base/lazy_instance.h" |
| 10 #include "base/memory/scoped_vector.h" | 10 #include "base/memory/scoped_vector.h" |
| (...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 456 if (test_webstore_installer_delegate) | 456 if (test_webstore_installer_delegate) |
| 457 test_webstore_installer_delegate->OnExtensionInstallSuccess(id); | 457 test_webstore_installer_delegate->OnExtensionInstallSuccess(id); |
| 458 | 458 |
| 459 SendResponse(true); | 459 SendResponse(true); |
| 460 | 460 |
| 461 // Matches the AddRef in RunImpl(). | 461 // Matches the AddRef in RunImpl(). |
| 462 Release(); | 462 Release(); |
| 463 } | 463 } |
| 464 | 464 |
| 465 void CompleteInstallFunction::OnExtensionInstallFailure( | 465 void CompleteInstallFunction::OnExtensionInstallFailure( |
| 466 const std::string& id, const std::string& error) { | 466 const std::string& id, |
| 467 if (test_webstore_installer_delegate) | 467 const std::string& error, |
| 468 test_webstore_installer_delegate->OnExtensionInstallFailure(id, error); | 468 WebstoreInstaller::FailureReason reason) { |
| 469 if (test_webstore_installer_delegate) { |
| 470 test_webstore_installer_delegate->OnExtensionInstallFailure( |
| 471 id, error, reason); |
| 472 } |
| 469 | 473 |
| 470 error_ = error; | 474 error_ = error; |
| 471 SendResponse(false); | 475 SendResponse(false); |
| 472 | 476 |
| 473 // Matches the AddRef in RunImpl(). | 477 // Matches the AddRef in RunImpl(). |
| 474 Release(); | 478 Release(); |
| 475 } | 479 } |
| 476 | 480 |
| 477 | 481 |
| 478 bool GetBrowserLoginFunction::RunImpl() { | 482 bool GetBrowserLoginFunction::RunImpl() { |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 519 feature_checker_->CheckGPUFeatureAvailability(); | 523 feature_checker_->CheckGPUFeatureAvailability(); |
| 520 return true; | 524 return true; |
| 521 } | 525 } |
| 522 | 526 |
| 523 void GetWebGLStatusFunction::OnFeatureCheck(bool feature_allowed) { | 527 void GetWebGLStatusFunction::OnFeatureCheck(bool feature_allowed) { |
| 524 CreateResult(feature_allowed); | 528 CreateResult(feature_allowed); |
| 525 SendResponse(true); | 529 SendResponse(true); |
| 526 } | 530 } |
| 527 | 531 |
| 528 } // namespace extensions | 532 } // namespace extensions |
| OLD | NEW |