Merge pull request #1204 from anapple/chromium-fun
Make chrome extensions compatible with latest API changes.
This commit is contained in:
commit
e00aa8e90b
@ -37,8 +37,8 @@ auto-update extensions on a daily basis (you can change this through the
|
||||
`extensions.update.interval` option in `about:config`).
|
||||
|
||||
For an experimental Chrome extension, get the code as explained below and issue `make extension`.
|
||||
Then open Chrome with the flag `--enable-experimental-extension-apis`, go to `Tools > Extension`
|
||||
and load the (unpackaged) extension from the directory `extensions/chrome`.
|
||||
Then open Chrome, go to `Tools > Extension` and load the (unpackaged) extension
|
||||
from the directory `build/chrome`.
|
||||
|
||||
### Getting the code
|
||||
|
||||
|
@ -3,7 +3,7 @@
|
||||
"version": "0.1",
|
||||
"description": "Read PDF Document",
|
||||
"permissions": [
|
||||
"experimental",
|
||||
"webRequest", "webRequestBlocking",
|
||||
"http://*/*.pdf",
|
||||
"file:///*/*.pdf"
|
||||
],
|
||||
|
@ -1,6 +1,6 @@
|
||||
<!doctype html>
|
||||
<script>
|
||||
chrome.experimental.webRequest.onBeforeRequest.addListener(
|
||||
chrome.webRequest.onBeforeRequest.addListener(
|
||||
function(details) {
|
||||
var viewerPage = 'content/web/viewer.html';
|
||||
var url = chrome.extension.getURL(viewerPage) + '?file=' + details.url;
|
||||
|
Loading…
Reference in New Issue
Block a user