equal
deleted
inserted
replaced
54 |
54 |
55 if (typeof this.min_x !== "undefined" && (x - this.__halfWidth < this.min_x)) { |
55 if (typeof this.min_x !== "undefined" && (x - this.__halfWidth < this.min_x)) { |
56 shift = Math.max(x - this.__halfWidth - this.min_x, - this.__maxShift); |
56 shift = Math.max(x - this.__halfWidth - this.min_x, - this.__maxShift); |
57 } |
57 } |
58 |
58 |
59 if (typeof this.max_x !== "undefined" && (x + this.__halfWidth > this.max_x)) { |
59 if (typeof this.max_x !== "undefined" && (+x + this.__halfWidth > this.max_x)) { |
60 shift = Math.min(x + this.__halfWidth - this.max_x, this.__maxShift); |
60 shift = Math.min(+ x + this.__halfWidth - this.max_x, this.__maxShift); |
61 } |
61 } |
62 |
62 |
63 this.$tooltip.css({ |
63 this.$tooltip.css({ |
64 "left" : (x - shift) + "px", |
64 "left" : (x - shift) + "px", |
65 "top" : y + "px" |
65 "top" : y + "px" |