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

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: Fix silly typo. 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
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 f0b64e49ab28c8a0b9d5c513544afffad9b45ba6..6961540103861ef74a3eb7dc0c5ed0b0b9cf3aba 100644
--- a/chrome/renderer/chrome_render_view_observer.cc
+++ b/chrome/renderer/chrome_render_view_observer.cc
@@ -430,8 +430,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;
}
@@ -439,7 +441,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;
}

Powered by Google App Engine
This is Rietveld 408576698