Chromium Code Reviews
DescriptionAdd stub functions for chrome.* APIs in content scripts.
Most of the extensions API is not supported in content scripts for security
purposes. Instead the typical pattern is to use messaging between content
scripts and a background page which executes them on behalf of the script.
This is not immediately obvious to many extension developers, so this
change adds an error message to help them better understand what's going on.
BUG=26128
TEST=Try writing a content script that uses some of the extensions API stuff
in chrome.tabs, chrome.windows, etc. You should see errors in the console
telling you that it isn't supported in content scripts.
Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=31958
Patch Set 1 #Patch Set 2 : '' #
Total comments: 19
Patch Set 3 : '' #Patch Set 4 : '' #
Total comments: 20
Patch Set 5 : '' #Patch Set 6 : '' #Messages
Total messages: 6 (0 generated)
|