Commit bf01441d authored by olau@iola.dk's avatar olau@iola.dk

Check position of placeholder before setting it

git-svn-id: https://flot.googlecode.com/svn/trunk@125 1e0a6537-2640-0410-bfb7-f154510ff394
parent cc517f69
......@@ -48,6 +48,8 @@ Bug fixes:
(reported by Khurram).
- Fixed a bug with returning y2 values in the selection event (fix
by exists, issue 75).
- Only set position relative on placeholder if it hasn't already a
position different from static (reported by kyberneticist, issue 95).
Flot 0.5
......
......@@ -330,7 +330,8 @@
canvasWidth = target.width();
canvasHeight = target.height();
target.html(""); // clear target
target.css("position", "relative"); // for positioning labels and overlay
if (target.css("position") == 'static')
target.css("position", "relative"); // for positioning labels and overlay
if (canvasWidth <= 0 || canvasHeight <= 0)
throw "Invalid dimensions for plot, width = " + canvasWidth + ", height = " + canvasHeight;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment