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

Issue 27408004: <webview>: Resolve relative paths as chrome-extension: URLs (Closed)

Created:
7 years, 2 months ago by Fady Samuel
Modified:
7 years, 1 month ago
Reviewers:
Charlie Reis
CC:
chromium-reviews, joi+watch-content_chromium.org, chromium-apps-reviews_chromium.org, darin-cc_chromium.org, jam, extensions-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Visibility:
Public.

Description

<webview>: Resolve relative paths as chrome-extension: URLs The CL performs URL resolution in the browser process out of convenience. If this was done in the embedder process in web_view.js then URL resolution would need to be done on both attribute mutation and initialization. BrowserPluginGuest::OnNavigateGuest gets called either way. When updating the src attribute on loadcommit, we can no longer do a simple string comparison, as the resolved URL may not match the developer-assigned URL. BUG=308114 Test=<webview src='guest.html'></webview> will attempt to resolve to chrome-extension://appID/guest.html. R=creis@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=232203

Patch Set 1 #

Patch Set 2 : Patch #

Patch Set 3 : Don't update src attribute with resolved URL. #

Total comments: 9

Patch Set 4 : Addressed creis's comments #

Total comments: 8

Patch Set 5 : Refactor + addressed creis' comments #

Total comments: 12

Patch Set 6 : New diff #

Patch Set 7 : Merge with ToT #

Unified diffs Side-by-side diffs Delta from patch set Stats (+47 lines, -1 line) Patch
M chrome/browser/apps/web_view_browsertest.cc View 1 2 3 4 1 chunk +7 lines, -0 lines 0 comments Download
M chrome/browser/guestview/webview/webview_guest.h View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/guestview/webview/webview_guest.cc View 1 2 3 4 5 6 3 chunks +13 lines, -0 lines 0 comments Download
M chrome/test/data/extensions/platform_apps/web_view/shim/main.js View 1 2 3 2 chunks +18 lines, -0 lines 0 comments Download
M content/browser/browser_plugin/browser_plugin_guest.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M content/public/browser/browser_plugin_guest_delegate.h View 1 chunk +3 lines, -0 lines 0 comments Download
M content/public/browser/browser_plugin_guest_delegate.cc View 1 chunk +4 lines, -0 lines 0 comments Download

Messages

Total messages: 11 (0 generated)
Fady Samuel
7 years, 2 months ago (2013-10-17 17:49:44 UTC) #1
Charlie Reis
https://codereview.chromium.org/27408004/diff/5001/chrome/browser/guestview/webview/webview_guest.cc File chrome/browser/guestview/webview/webview_guest.cc (right): https://codereview.chromium.org/27408004/diff/5001/chrome/browser/guestview/webview/webview_guest.cc#newcode561 chrome/browser/guestview/webview/webview_guest.cc:561: embedder_site_url.host().c_str())); What will this do in Hui's case, when ...
7 years, 2 months ago (2013-10-18 17:37:54 UTC) #2
Fady Samuel
This CL was on hold as I was distracted with the declarative WebRequest API. I've ...
7 years, 1 month ago (2013-10-25 21:10:31 UTC) #3
Charlie Reis
Thanks. The lifetime of extension_id is a bit awkward to understand, but I don't think ...
7 years, 1 month ago (2013-10-29 21:11:38 UTC) #4
Fady Samuel
This has been significantly simplified. PTAL. https://codereview.chromium.org/27408004/diff/69001/chrome/browser/guestview/guestview.cc File chrome/browser/guestview/guestview.cc (right): https://codereview.chromium.org/27408004/diff/69001/chrome/browser/guestview/guestview.cc#newcode103 chrome/browser/guestview/guestview.cc:103: extension_id_ = extension_id; ...
7 years, 1 month ago (2013-10-30 19:48:51 UTC) #5
Charlie Reis
This is potentially much better, but I don't understand it. Some of the questions below ...
7 years, 1 month ago (2013-10-30 20:42:20 UTC) #6
Fady Samuel
PTAL. This CL is much simpler and more obvious now. The comments below are for ...
7 years, 1 month ago (2013-10-31 17:25:17 UTC) #7
Charlie Reis
LGTM. (Do we not need ResolveURL in AdView?)
7 years, 1 month ago (2013-10-31 17:35:25 UTC) #8
Fady Samuel
On 2013/10/31 17:35:25, creis wrote: > LGTM. (Do we not need ResolveURL in AdView?) We ...
7 years, 1 month ago (2013-10-31 18:31:07 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/fsamuel@chromium.org/27408004/299001
7 years, 1 month ago (2013-10-31 18:32:19 UTC) #10
Fady Samuel
7 years, 1 month ago (2013-10-31 20:51:38 UTC) #11
Message was sent while issue was closed.
Committed patchset #7 manually as r232203 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698