forked from 0x2620/oxjs
refactoring
This commit is contained in:
parent
ab68c4a54f
commit
9ee0742b53
6 changed files with 15 additions and 13 deletions
|
|
@ -18,6 +18,12 @@ Ox.Tooltip = function(options, self) {
|
|||
title: ''
|
||||
})
|
||||
.options(options || {})
|
||||
.update({
|
||||
title: function() {
|
||||
that.html(value);
|
||||
value === '' && that.detach();
|
||||
}
|
||||
})
|
||||
.addClass('OxTooltip')
|
||||
.html(self.options.title);
|
||||
|
||||
|
|
@ -27,8 +33,7 @@ Ox.Tooltip = function(options, self) {
|
|||
|
||||
self.setOption = function(key, value) {
|
||||
if (key == 'title') {
|
||||
that.html(value);
|
||||
value === '' && that.detach();
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue