From 0acb14c5a01fe4da277df45a64dbd1de13c9b5cc Mon Sep 17 00:00:00 2001 From: Chris Date: Mon, 9 Feb 2015 17:21:50 -0700 Subject: [PATCH] Safari update link and minor popup improvement --- platform/safari/Update.plist | 2 +- platform/safari/vapi-background.js | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/platform/safari/Update.plist b/platform/safari/Update.plist index ed493e9ae..1b0c141a4 100644 --- a/platform/safari/Update.plist +++ b/platform/safari/Update.plist @@ -14,7 +14,7 @@ CFBundleVersion {buildNumber} URL - https://chrismatic.io/ublock/ublock-0.8.6.0.safariextz + https://chrismatic.io/ublock/ublock-latest.safariextz diff --git a/platform/safari/vapi-background.js b/platform/safari/vapi-background.js index 78b2077c5..672a56d70 100644 --- a/platform/safari/vapi-background.js +++ b/platform/safari/vapi-background.js @@ -431,8 +431,11 @@ // reload the popup when that is opened safari.application.addEventListener('popover', function(e) { - e.target.contentWindow.document.body.textContent = ''; - e.target.contentWindow.location.reload(); + var w = e.target.contentWindow, body = w.document.body, child; + while(child = body.firstChild) { + body.removeChild(child); + } + w.location.reload(); }, true); /******************************************************************************/