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/lazy_instance.h" | 7 #include "base/lazy_instance.h" |
8 #include "base/memory/scoped_vector.h" | 8 #include "base/memory/scoped_vector.h" |
9 #include "base/string_util.h" | 9 #include "base/string_util.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
351 const std::string& id, | 351 const std::string& id, |
352 const SkBitmap& icon, | 352 const SkBitmap& icon, |
353 DictionaryValue* parsed_manifest) { | 353 DictionaryValue* parsed_manifest) { |
354 CHECK_EQ(id_, id); | 354 CHECK_EQ(id_, id); |
355 CHECK(parsed_manifest); | 355 CHECK(parsed_manifest); |
356 icon_ = icon; | 356 icon_ = icon; |
357 parsed_manifest_.reset(parsed_manifest); | 357 parsed_manifest_.reset(parsed_manifest); |
358 | 358 |
359 std::string error; | 359 std::string error; |
360 dummy_extension_ = ExtensionInstallPrompt::GetLocalizedExtensionForDisplay( | 360 dummy_extension_ = ExtensionInstallPrompt::GetLocalizedExtensionForDisplay( |
361 parsed_manifest_.get(), id, localized_name_, "", &error); | 361 parsed_manifest_.get(), |
362 Extension::FROM_WEBSTORE, | |
Aaron Boodman
2012/07/31 09:55:59
I am not sure this is the only flag that should be
not at google - send to devlin
2012/07/31 12:11:32
It looks like the interesting code is in Installed
| |
363 id, | |
364 localized_name_, | |
365 "", | |
366 &error); | |
362 | 367 |
363 if (!dummy_extension_) { | 368 if (!dummy_extension_) { |
364 OnWebstoreParseFailure(id_, WebstoreInstallHelper::Delegate::MANIFEST_ERROR, | 369 OnWebstoreParseFailure(id_, WebstoreInstallHelper::Delegate::MANIFEST_ERROR, |
365 kInvalidManifestError); | 370 kInvalidManifestError); |
366 return; | 371 return; |
367 } | 372 } |
368 | 373 |
369 install_prompt_.reset( | 374 install_prompt_.reset( |
370 chrome::CreateExtensionInstallPromptWithBrowser(GetCurrentBrowser())); | 375 chrome::CreateExtensionInstallPromptWithBrowser(GetCurrentBrowser())); |
371 install_prompt_->ConfirmWebstoreInstall(this, dummy_extension_, &icon_); | 376 install_prompt_->ConfirmWebstoreInstall(this, dummy_extension_, &icon_); |
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
594 feature_checker_->CheckGPUFeatureAvailability(); | 599 feature_checker_->CheckGPUFeatureAvailability(); |
595 return true; | 600 return true; |
596 } | 601 } |
597 | 602 |
598 void GetWebGLStatusFunction::OnFeatureCheck(bool feature_allowed) { | 603 void GetWebGLStatusFunction::OnFeatureCheck(bool feature_allowed) { |
599 CreateResult(feature_allowed); | 604 CreateResult(feature_allowed); |
600 SendResponse(true); | 605 SendResponse(true); |
601 } | 606 } |
602 | 607 |
603 } // namespace extensions | 608 } // namespace extensions |
OLD | NEW |