| Index: safari/include.youtube.js |
| =================================================================== |
| --- a/safari/include.youtube.js |
| +++ b/safari/include.youtube.js |
| @@ -17,16 +17,18 @@ |
| (function() { |
| if (document.domain != "www.youtube.com") |
| return; |
| var usingContentBlockerAPI = true; |
| try |
| { |
| + var beforeLoadEvent = document.createEvent("Event"); |
|
Sebastian Noack
2016/06/11 20:56:34
I wonder whether we couldn't simply use ext.backgr
Sebastian Noack
2016/06/11 21:00:30
sendMessageSync() I meant.
|
| + beforeLoadEvent.initEvent("beforeload"); |
| if (safari.self.tab.canLoad(beforeLoadEvent, |
| {category: "request", |
| payload: {type: "prefs.get", |
| key: "safariContentBlocker"}}) != true) |
| usingContentBlockerAPI = false; |
| } |
| catch (e) |
| { |