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

Unified Diff: chrome/renderer/chrome_render_view_observer.cc

Issue 8312005: Ignore paths when matching patterns for extensions. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 9 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/common/render_messages.h ('k') | content/browser/mock_content_browser_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/chrome_render_view_observer.cc
diff --git a/chrome/renderer/chrome_render_view_observer.cc b/chrome/renderer/chrome_render_view_observer.cc
index 36fe553d6022982efb4936d3e2ff1125dc2a8885..feee9616994e105e212076ef27dc0d802e0323de 100644
--- a/chrome/renderer/chrome_render_view_observer.cc
+++ b/chrome/renderer/chrome_render_view_observer.cc
@@ -429,8 +429,10 @@ bool ChromeRenderViewObserver::allowStorage(WebFrame* frame, bool local) {
bool ChromeRenderViewObserver::allowReadFromClipboard(WebFrame* frame,
bool default_value) {
bool allowed = false;
+ // TODO(dcheng): Should we consider a toURL() method on WebSecurityOrigin?
Send(new ChromeViewHostMsg_CanTriggerClipboardRead(
- routing_id(), frame->document().url(), &allowed));
+ routing_id(), GURL(frame->document().securityOrigin().toString().utf8()),
+ &allowed));
return allowed;
}
@@ -438,7 +440,8 @@ bool ChromeRenderViewObserver::allowWriteToClipboard(WebFrame* frame,
bool default_value) {
bool allowed = false;
Send(new ChromeViewHostMsg_CanTriggerClipboardWrite(
- routing_id(), frame->document().url(), &allowed));
+ routing_id(), GURL(frame->document().securityOrigin().toString().utf8()),
+ &allowed));
return allowed;
}
« no previous file with comments | « chrome/common/render_messages.h ('k') | content/browser/mock_content_browser_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698