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

Issue 4727001: Split the private webstore install API into two parts.... (Closed)

Created:
10 years, 1 month ago by asargent_no_longer_on_chrome
Modified:
9 years, 7 months ago
CC:
chromium-reviews, Aaron Boodman, Erik does not do reviews, Paweł Hajdan Jr., pam+watch_chromium.org, ben+cc_chromium.org
Visibility:
Public.

Description

Split the private webstore install API into two parts. The first part, beginInstall, must be called during a user gesture. The second part should supply a matching id and actually starts the download and install process. BUG=61954 TEST=Requires webstore server side changes before it can be fully tested. For now, you can test that visiting the webstore and running something like the following command in the javascript console generates an error: chrome.webstorePrivate.beginInstall("mihcahmgecmbnbcchbopgniflfhgnkff") Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=65722

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Total comments: 16

Patch Set 4 : '' #

Total comments: 7

Patch Set 5 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+203 lines, -86 lines) Patch
M chrome/browser/extensions/crx_installer.h View 1 1 chunk +3 lines, -0 lines 0 comments Download
M chrome/browser/extensions/crx_installer.cc View 1 5 chunks +15 lines, -15 lines 0 comments Download
M chrome/browser/extensions/crx_installer_browsertest.cc View 2 chunks +2 lines, -1 line 0 comments Download
M chrome/browser/extensions/extension_function_dispatcher.cc View 1 2 3 1 chunk +2 lines, -1 line 0 comments Download
M chrome/browser/extensions/extension_gallery_install_apitest.cc View 1 2 3 2 chunks +23 lines, -11 lines 0 comments Download
M chrome/browser/extensions/extension_webstore_private_api.h View 1 2 3 1 chunk +13 lines, -4 lines 0 comments Download
M chrome/browser/extensions/extension_webstore_private_api.cc View 1 2 3 4 chunks +47 lines, -6 lines 0 comments Download
M chrome/common/extensions/api/extension_api.json View 1 1 chunk +34 lines, -0 lines 0 comments Download
A chrome/test/data/extensions/api_test/extension_gallery_install/common.js View 4 1 chunk +20 lines, -0 lines 0 comments Download
A chrome/test/data/extensions/api_test/extension_gallery_install/complete_without_begin.html View 1 chunk +11 lines, -0 lines 0 comments Download
A chrome/test/data/extensions/api_test/extension_gallery_install/invalid_begin.html View 4 1 chunk +8 lines, -0 lines 0 comments Download
A chrome/test/data/extensions/api_test/extension_gallery_install/no_user_gesture.html View 1 chunk +10 lines, -0 lines 0 comments Download
M chrome/test/data/extensions/api_test/extension_gallery_install/test.html View 1 2 3 4 1 chunk +15 lines, -48 lines 0 comments Download

Messages

Total messages: 5 (0 generated)
asargent_no_longer_on_chrome
10 years, 1 month ago (2010-11-09 01:17:05 UTC) #1
Erik does not do reviews
http://codereview.chromium.org/4727001/diff/16001/17001 File chrome/browser/extensions/crx_installer.cc (right): http://codereview.chromium.org/4727001/diff/16001/17001#newcode302 chrome/browser/extensions/crx_installer.cc:302: extension_->plugins().empty() && is_gallery_install_; just curious, why is this extra ...
10 years, 1 month ago (2010-11-09 16:32:21 UTC) #2
asargent_no_longer_on_chrome
new version addressing comments http://codereview.chromium.org/4727001/diff/16001/chrome/browser/extensions/crx_installer.cc File chrome/browser/extensions/crx_installer.cc (right): http://codereview.chromium.org/4727001/diff/16001/chrome/browser/extensions/crx_installer.cc#newcode302 chrome/browser/extensions/crx_installer.cc:302: extension_->plugins().empty() && is_gallery_install_; On 2010/11/09 ...
10 years, 1 month ago (2010-11-10 00:23:48 UTC) #3
Erik does not do reviews
LGTM http://codereview.chromium.org/4727001/diff/26001/chrome/test/data/extensions/api_test/extension_gallery_install/common.js File chrome/test/data/extensions/api_test/extension_gallery_install/common.js (right): http://codereview.chromium.org/4727001/diff/26001/chrome/test/data/extensions/api_test/extension_gallery_install/common.js#newcode14 chrome/test/data/extensions/api_test/extension_gallery_install/common.js:14: extensions.forEach(function(extension) { you can use one of the ...
10 years, 1 month ago (2010-11-10 16:47:44 UTC) #4
asargent_no_longer_on_chrome
10 years, 1 month ago (2010-11-10 22:58:23 UTC) #5
[final version for the record]

http://codereview.chromium.org/4727001/diff/26001/chrome/test/data/extensions...
File chrome/test/data/extensions/api_test/extension_gallery_install/common.js
(right):

http://codereview.chromium.org/4727001/diff/26001/chrome/test/data/extensions...
chrome/test/data/extensions/api_test/extension_gallery_install/common.js:14:
extensions.forEach(function(extension) {
On 2010/11/10 16:47:45, Erik Kay wrote:
> you can use one of the more recent built-in array functions for this:
> callback(extensions.some(function(ext) { return extension_id == ext.id); });

nice - I hadn't heard of that one before. done.

http://codereview.chromium.org/4727001/diff/26001/chrome/test/data/extensions...
File
chrome/test/data/extensions/api_test/extension_gallery_install/invalid_begin.html
(right):

http://codereview.chromium.org/4727001/diff/26001/chrome/test/data/extensions...
chrome/test/data/extensions/api_test/extension_gallery_install/invalid_begin.html:8:
chrome.webstorePrivate.completeInstall(extension_id, function() {
On 2010/11/10 16:47:45, Erik Kay wrote:
> this seems redundant since you already have the separate complete without
begin
> test.  if you want to test that complete doesn't trigger just because someone
> called begin before, then it seems like a better test would be to try a
> different valid id for begin.  I'm still not sure that's very interesting
> though.
Agreed - I've removed this part.

http://codereview.chromium.org/4727001/diff/26001/chrome/test/data/extensions...
File chrome/test/data/extensions/api_test/extension_gallery_install/test.html
(right):

http://codereview.chromium.org/4727001/diff/26001/chrome/test/data/extensions...
chrome/test/data/extensions/api_test/extension_gallery_install/test.html:3: //
This tests that the management beginInstall and completeInstall functions.
On 2010/11/10 16:47:45, Erik Kay wrote:
> "that the"?
fixed

Powered by Google App Engine
This is Rietveld 408576698