--- a/src/widgets/Tooltip.js Wed Dec 19 19:02:52 2012 +0100
+++ b/src/widgets/Tooltip.js Thu Jan 17 17:25:46 2013 +0100
@@ -56,8 +56,8 @@
shift = Math.max(x - this.__halfWidth - this.min_x, - this.__maxShift);
}
- if (typeof this.max_x !== "undefined" && (x + this.__halfWidth > this.max_x)) {
- shift = Math.min(x + this.__halfWidth - this.max_x, this.__maxShift);
+ if (typeof this.max_x !== "undefined" && (+x + this.__halfWidth > this.max_x)) {
+ shift = Math.min(+ x + this.__halfWidth - this.max_x, this.__maxShift);
}
this.$tooltip.css({