fix for cases where passing an array of tooltips as an option to Ox.Button would cause Ox.Element to actually set the tooltip to that array
This commit is contained in:
parent
2df5d05980
commit
5a23d8936b
4 changed files with 18 additions and 9 deletions
|
|
@ -251,6 +251,8 @@ Ox.Element = function(options, self) {
|
|||
});
|
||||
that.bind({
|
||||
mouseenter: mouseenter
|
||||
}).unbind({
|
||||
mousemove: mousemove
|
||||
});
|
||||
} else {
|
||||
that.$tooltip = Ox.Tooltip({
|
||||
|
|
@ -258,13 +260,22 @@ Ox.Element = function(options, self) {
|
|||
});
|
||||
that.bind({
|
||||
mousemove: mousemove
|
||||
}).unbind({
|
||||
mouseenter: mouseenter
|
||||
});
|
||||
}
|
||||
that.bind({
|
||||
mouseleave: mouseleave
|
||||
});
|
||||
} else {
|
||||
that.$tooltip && that.$tooltip.remove();
|
||||
if (that.$tooltip) {
|
||||
that.$tooltip.remove();
|
||||
that.unbind({
|
||||
mouseenter: mouseenter,
|
||||
mousemove: mousemove,
|
||||
mouseleave: mouseleave
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -277,8 +288,6 @@ Ox.Element = function(options, self) {
|
|||
}
|
||||
};
|
||||
|
||||
that._self = self; // fixme: remove
|
||||
|
||||
/*@
|
||||
bindEvent <function> Binds a function to an event
|
||||
(event, callback) -> <o> This element
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue