diff options
Diffstat (limited to 'templates/html/svgpan.js')
-rw-r--r-- | templates/html/svgpan.js | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/templates/html/svgpan.js b/templates/html/svgpan.js index 4218e79..db9fcb9 100644 --- a/templates/html/svgpan.js +++ b/templates/html/svgpan.js @@ -89,9 +89,13 @@ function show() function init(evt) { svgDoc = evt.target.ownerDocument; - if (top.window && top.window.registerShow) // register show function in html doc for dynamic sections - { - top.window.registerShow(sectionId,show); + try { + if (top.window && top.window.registerShow) { // register show function in html doc for dynamic sections + top.window.registerShow(sectionId,show); + } + } catch(e) { + // ugh, we are not allowed to talk to the parent; can happen with Chrome when viewing pages + // locally, since they treat every local page as having a different origin } show(); |