summaryrefslogtreecommitdiffstats
path: root/dist/svg.js
diff options
context:
space:
mode:
authorUlrich-Matthias Schäfer <ulima.ums@googlemail.com>2015-10-22 17:20:45 +0200
committerUlrich-Matthias Schäfer <ulima.ums@googlemail.com>2015-10-22 17:20:45 +0200
commit0b5b0eb4842c0bad045a69981d00cba7010f8d31 (patch)
tree44589fb7ff91d134c7e10b3e46f2242623e1484c /dist/svg.js
parent8617a6b5d5ff147718051a7fc582c54f603aa90f (diff)
downloadsvg.js-0b5b0eb4842c0bad045a69981d00cba7010f8d31.tar.gz
svg.js-0b5b0eb4842c0bad045a69981d00cba7010f8d31.zip
bbox loop (fix #392)
Diffstat (limited to 'dist/svg.js')
-rw-r--r--dist/svg.js8
1 files changed, 3 insertions, 5 deletions
diff --git a/dist/svg.js b/dist/svg.js
index 07be53d..37f94df 100644
--- a/dist/svg.js
+++ b/dist/svg.js
@@ -6,7 +6,7 @@
* @copyright Wout Fierens <wout@impinc.co.uk>
* @license MIT
*
-* BUILT: Sun Oct 11 2015 21:55:27 GMT+0200 (Mitteleuropäische Sommerzeit)
+* BUILT: Thu Oct 22 2015 17:18:44 GMT+0200 (Mitteleuropäische Sommerzeit)
*/;
(function(root, factory) {
@@ -1594,13 +1594,11 @@ SVG.BBox = SVG.invent({
// find native bbox
box = element.node.getBBox()
} catch(e) {
- try{
- // clone element to visible place to get bbox (FF fix)
+ if(element instanceof SVG.Shape){
var clone = element.clone().addTo(SVG.parser.draw)
box = clone.bbox()
clone.remove()
- } catch(e) {
- // mimic bbox
+ }else{
box = {
x: element.node.clientLeft
, y: element.node.clientTop