1
0
Fork 0
forked from 0x2620/oxjs

self.setOption ~> that.update

This commit is contained in:
j 2012-05-28 19:35:41 +00:00
commit 005d50c389
56 changed files with 919 additions and 933 deletions

View file

@ -39,6 +39,18 @@ Ox.ListMap = function(options, self) {
width: 256
})
.options(options || {})
.update({
height: function() {
self.$list.size();
self.$map.resizeMap();
},
selected: function() {
self.$list.options({selected: self.options.selected});
},
width: function() {
self.$map.resizeMap();
}
})
.css({
width: self.options.width + 'px',
height: self.options.height + 'px'
@ -1119,20 +1131,6 @@ Ox.ListMap = function(options, self) {
});
}
/*@
setOption <f> setOption
@*/
self.setOption = function(key, value) {
if (key == 'height') {
self.$list.size();
self.$map.resizeMap();
} else if (key == 'selected') {
self.$list.options({selected: value});
} else if (key == 'width') {
self.$map.resizeMap();
}
}
/*@
focusList <f> focusList
@*/