1
0
Fork 0
forked from 0x2620/oxjs

use Ox.Log

This commit is contained in:
j 2011-11-04 16:54:28 +01:00
commit dce2843303
50 changed files with 276 additions and 276 deletions

View file

@ -64,7 +64,7 @@ Ox.Select = function(options, self) {
key_down: showMenu
});
//Ox.print('Ox.Select', self.options);
//Ox.Log('Form', 'Ox.Select', self.options);
Ox.extend(self, {
buttonId: self.options.id + 'Button',
@ -147,7 +147,7 @@ Ox.Select = function(options, self) {
}
function changeMenu(data) {
//Ox.print('clickMenu: ', self.options.id, data)
//Ox.Log('Form', 'clickMenu: ', self.options.id, data)
if (self.options.selectable) {
self.checked = self.optionGroup.checked();
self.options.value = data.checked[0].id;
@ -163,10 +163,10 @@ Ox.Select = function(options, self) {
}
function hideMenu() {
//Ox.print('%% hideMenu that', that, 'self', self)
//Ox.Log('Form', '%% hideMenu that', that, 'self', self)
that.removeClass('OxSelected');
// self.$button.removeClass('OxSelected');
//Ox.print('%% hideMenu end')
//Ox.Log('Form', '%% hideMenu end')
}
function loseFocus() {
@ -182,7 +182,7 @@ Ox.Select = function(options, self) {
self.setOption = function(key, value) {
if (key == 'value') {
Ox.print('SETTING VALUE OPTION', value)
Ox.Log('Form', 'SETTING VALUE OPTION', value)
that.selectItem(value);
}
};
@ -216,7 +216,7 @@ Ox.Select = function(options, self) {
id <s> item id
@*/
that.selectItem = function(id) {
Ox.print('selectItem', id, self.options.items, self.options.items.length, Ox.getObjectById(self.options.items, id))
Ox.Log('Form', 'selectItem', id, self.options.items, self.options.items.length, Ox.getObjectById(self.options.items, id))
self.options.type == 'text' && self.$title.html(
Ox.getObjectById(self.options.items, id).title
);
@ -236,13 +236,13 @@ Ox.Select = function(options, self) {
that.value = function() {
if (arguments.length == 0) {
//Ox.print('selected::', that.selected())
//Ox.Log('Form', 'selected::', that.selected())
return that.selected()[0].id;
} else {
that.selectItem(arguments[0]);
return that;
/*
Ox.print('ELSE');
Ox.Log('Form', 'ELSE');
that.selectItem(arguments[0]);
return that;
*/