/* start module: util */
$pyjs['loaded_modules']['util'] = function (__mod_name__) {
	if($pyjs['loaded_modules']['util']['__was_initialized__']) return $pyjs['loaded_modules']['util'];
	var $m = $pyjs['loaded_modules']['util'];
	$m['__repr__'] = function() { return '<module: util>'; };
	$m['__was_initialized__'] = true;
	if ((__mod_name__ === null) || (typeof __mod_name__ == 'undefined')) __mod_name__ = 'util';
	$m['__name__'] = __mod_name__;


	$m['prnt'] = $p['___import___']('prnt.prnt', null, null, false);
	$m['Calendar'] = $p['___import___']('pyjamas.ui.Calendar.Calendar', null, null, false);
	$m['DateField'] = $p['___import___']('pyjamas.ui.Calendar.DateField', null, null, false);
	$m['RootPanel'] = $p['___import___']('pyjamas.ui.RootPanel.RootPanel', null, null, false);
	$m['VerticalPanel'] = $p['___import___']('pyjamas.ui.VerticalPanel.VerticalPanel', null, null, false);
	$m['HorizontalPanel'] = $p['___import___']('pyjamas.ui.HorizontalPanel.HorizontalPanel', null, null, false);
	$m['SimplePanel'] = $p['___import___']('pyjamas.ui.SimplePanel.SimplePanel', null, null, false);
	$m['DisclosurePanel'] = $p['___import___']('pyjamas.ui.DisclosurePanel.DisclosurePanel', null, null, false);
	$m['DialogBox'] = $p['___import___']('pyjamas.ui.DialogBox.DialogBox', null, null, false);
	$m['TabPanel'] = $p['___import___']('pyjamas.ui.TabPanel.TabPanel', null, null, false);
	$m['Grid'] = $p['___import___']('pyjamas.ui.Grid.Grid', null, null, false);
	$m['Frame'] = $p['___import___']('pyjamas.ui.Frame.Frame', null, null, false);
	$m['TextBox'] = $p['___import___']('pyjamas.ui.TextBox.TextBox', null, null, false);
	$m['TextArea'] = $p['___import___']('pyjamas.ui.TextArea.TextArea', null, null, false);
	$m['HTML'] = $p['___import___']('pyjamas.ui.HTML.HTML', null, null, false);
	$m['FlowPanel'] = $p['___import___']('pyjamas.ui.FlowPanel.FlowPanel', null, null, false);
	$m['FlexTable'] = $p['___import___']('pyjamas.ui.FlexTable.FlexTable', null, null, false);
	$m['Anchor'] = $p['___import___']('pyjamas.ui.Anchor.Anchor', null, null, false);
	$m['FlexCellFormatter'] = $p['___import___']('pyjamas.ui.FlexCellFormatter.FlexCellFormatter', null, null, false);
	$m['Label'] = $p['___import___']('pyjamas.ui.Label.Label', null, null, false);
	$m['CheckBox'] = $p['___import___']('pyjamas.ui.CheckBox.CheckBox', null, null, false);
	$m['ListBox'] = $p['___import___']('pyjamas.ui.ListBox.ListBox', null, null, false);
	$m['Button'] = $p['___import___']('pyjamas.ui.Button.Button', null, null, false);
	$m['ToggleButton'] = $p['___import___']('pyjamas.ui.ToggleButton.ToggleButton', null, null, false);
	$m['PopupPanel'] = $p['___import___']('pyjamas.ui.PopupPanel.PopupPanel', null, null, false);
	$m['KeyboardHandler'] = $p['___import___']('pyjamas.ui.KeyboardListener.KeyboardHandler', null, null, false);
	$m['FocusHandler'] = $p['___import___']('pyjamas.ui.FocusListener.FocusHandler', null, null, false);
	$m['Tree'] = $p['___import___']('pyjamas.ui.Tree.Tree', null, null, false);
	$m['TreeItem'] = $p['___import___']('pyjamas.ui.Tree.TreeItem', null, null, false);
	$m['Image'] = $p['___import___']('pyjamas.ui.Image.Image', null, null, false);
	$m['HasAlignment'] = $p['___import___']('pyjamas.ui.HasAlignment', null, null, false);
	$m['HorizontalSplitPanel'] = $p['___import___']('pyjamas.ui.HorizontalSplitPanel', null, null, false);
	$m['FocusListener'] = $p['___import___']('pyjamas.ui.FocusListener', null, null, false);
	$m['MenuBar'] = $p['___import___']('pyjamas.ui.MenuBar.MenuBar', null, null, false);
	$m['MenuItem'] = $p['___import___']('pyjamas.ui.MenuItem.MenuItem', null, null, false);
	$m['Widget'] = $p['___import___']('pyjamas.ui.Widget.Widget', null, null, false);
	$m['Hyperlink'] = $p['___import___']('pyjamas.ui.Hyperlink.Hyperlink', null, null, false);
	$m['Window'] = $p['___import___']('pyjamas.Window', null, null, false);
	$m['Timer'] = $p['___import___']('pyjamas.Timer.Timer', null, null, false);
	$m['date'] = $p['___import___']('datetime.date', null, null, false);
	$m['time'] = $p['___import___']('datetime.time', null, null, false);
	$m['datetime'] = $p['___import___']('datetime.datetime', null, null, false);
	$m['timedelta'] = $p['___import___']('datetime.timedelta', null, null, false);
	$m['DissolvingPopup'] = $p['___import___']('DissolvingPopup.DissolvingPopup', null, null, false);
	$m['HTMLPanel'] = $p['___import___']('pyjamas.ui.HTMLPanel.HTMLPanel', null, null, false);
	$m['JsonHandler'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(callback, callback_error, data) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				callback = arguments[1];
				callback_error = arguments[2];
				data = arguments[3];
			}
			if (typeof callback_error == 'undefined') callback_error=arguments['callee']['__args__'][4][1];
			if (typeof data == 'undefined') data=arguments['callee']['__args__'][5][1];

			self['callback'] = callback;
			self['callback_error'] = callback_error;
			self['data'] = data;
			return null;
		}
	, 1, [null,null,['self'],['callback'],['callback_error', null],['data', null]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onRemoteResponse', function(res) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				res = arguments[1];
			}

			if ($p['bool'](($p['getattr'](self, 'callback') !== null))) {
				if ($p['bool']($p['isinstance']($p['getattr'](self, 'callback'), $p['str']))) {
					$m['DissolvingPopup']($p['getattr'](self, 'callback'));
				}
				else if ($p['bool'](($p['getattr'](self, 'data') === null))) {
					self['callback'](res);
				}
				else {
					self['callback'](res, $p['getattr'](self, 'data'));
				}
			}
			return null;
		}
	, 1, [null,null,['self'],['res']]);
		$cls_definition['onRemoteResponse'] = $method;
		$method = $pyjs__bind_method2('onRemoteError', function(text, code) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				text = arguments[1];
				code = arguments[2];
			}

			if ($p['bool'](($p['getattr'](self, 'callback_error') !== null))) {
				if ($p['bool'](($p['getattr'](self, 'data') === null))) {
					self['callback_error'](text, code);
				}
				else {
					self['callback'](text, code, $p['getattr'](self, 'data'));
				}
			}
			else {
				$m['prnt'](text);
				$m['prnt'](code);
			}
			return null;
		}
	, 1, [null,null,['self'],['text'],['code']]);
		$cls_definition['onRemoteError'] = $method;
		var $bases = new Array(pyjslib['object']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('JsonHandler', $p['tuple']($bases), $data);
	})();
	$m['MyKeyboardHandler'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(callback) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				callback = arguments[1];
			}

			self['callback'] = callback;
			return null;
		}
	, 1, [null,null,['self'],['callback']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onKeyDown', function(res) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				res = arguments[1];
			}

			self['callback']();
			return null;
		}
	, 1, [null,null,['self'],['res']]);
		$cls_definition['onKeyDown'] = $method;
		var $bases = new Array($m['KeyboardHandler']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('MyKeyboardHandler', $p['tuple']($bases), $data);
	})();
	$m['redirect'] = function(url) {

$wnd.location.replace(url);
	};
	$m['redirect']['__name__'] = 'redirect';

	$m['redirect']['__bind_type__'] = 0;
	$m['redirect']['__args__'] = [null,null,['url']];
	$m['date2mysql'] = function(d) {

		return d['strftime']('%Y-%m-%d');
	};
	$m['date2mysql']['__name__'] = 'date2mysql';

	$m['date2mysql']['__bind_type__'] = 0;
	$m['date2mysql']['__args__'] = [null,null,['d']];
	$m['mysql2date'] = function(s) {

		return $pyjs_kwargs_call(null, $m['date'], null, null, [{'year':$p['float_int']($p['__getslice'](s, 0, 4)), 'month':$p['float_int']($p['__getslice'](s, 5, 7)), 'day':$p['float_int']($p['__getslice'](s, 8, 10))}]);
	};
	$m['mysql2date']['__name__'] = 'mysql2date';

	$m['mysql2date']['__bind_type__'] = 0;
	$m['mysql2date']['__args__'] = [null,null,['s']];
	$m['date2italian'] = function(d) {

		return d['strftime']('%d/%m/%Y');
	};
	$m['date2italian']['__name__'] = 'date2italian';

	$m['date2italian']['__bind_type__'] = 0;
	$m['date2italian']['__args__'] = [null,null,['d']];
	$m['italian2date'] = function(s) {

		return $pyjs_kwargs_call(null, $m['date'], null, null, [{'year':$p['float_int']($p['__getslice'](s, 6, 10)), 'month':$p['float_int']($p['__getslice'](s, 3, 5)), 'day':$p['float_int']($p['__getslice'](s, 0, 2))}]);
	};
	$m['italian2date']['__name__'] = 'italian2date';

	$m['italian2date']['__bind_type__'] = 0;
	$m['italian2date']['__args__'] = [null,null,['s']];
	$m['datetime2mysql'] = function(dt) {

		return dt['strftime']('%Y-%m-%d %H:%M:%S');
	};
	$m['datetime2mysql']['__name__'] = 'datetime2mysql';

	$m['datetime2mysql']['__bind_type__'] = 0;
	$m['datetime2mysql']['__args__'] = [null,null,['dt']];
	$m['mysql2datetime'] = function(s) {

		return $pyjs_kwargs_call(null, $m['datetime'], null, null, [{'year':$p['float_int']($p['__getslice'](s, 0, 4)), 'month':$p['float_int']($p['__getslice'](s, 5, 7)), 'day':$p['float_int']($p['__getslice'](s, 8, 10)), 'hour':$p['float_int']($p['__getslice'](s, 9, 11)), 'minute':$p['float_int']($p['__getslice'](s, 12, 14)), 'second':$p['float_int']($p['__getslice'](s, 15, 17))}]);
	};
	$m['mysql2datetime']['__name__'] = 'mysql2datetime';

	$m['mysql2datetime']['__bind_type__'] = 0;
	$m['mysql2datetime']['__args__'] = [null,null,['s']];
	$m['validateMandatory'] = function(tbs) {
		var $iter1_nextval,$iter1_type,$iter1_iter,$iter1_array,error,tb,$iter1_idx;
		error = false;
		$iter1_iter = tbs;
		$iter1_nextval=$p['__iter_prepare']($iter1_iter,false);
		while (typeof($p['__wrapped_next']($iter1_nextval)['$nextval']) != 'undefined') {
			tb = $iter1_nextval['$nextval'];
			if ($p['bool']($p['op_eq'](tb['getText'](), ''))) {
				tb['addStyleName']('validation-error');
				error = true;
			}
		}
		return !$p['bool'](error);
	};
	$m['validateMandatory']['__name__'] = 'validateMandatory';

	$m['validateMandatory']['__bind_type__'] = 0;
	$m['validateMandatory']['__args__'] = [null,null,['tbs']];
	$m['validateInteger'] = function(tbs) {
		var $iter2_nextval,$iter2_type,$iter2_iter,$iter2_idx,error,tb,$iter2_array;
		error = false;
		$iter2_iter = tbs;
		$iter2_nextval=$p['__iter_prepare']($iter2_iter,false);
		while (typeof($p['__wrapped_next']($iter2_nextval)['$nextval']) != 'undefined') {
			tb = $iter2_nextval['$nextval'];
			if ($p['bool'](!$p['bool'](tb['getText']()['isdigit']()))) {
				tb['addStyleName']('validation-error');
				error = true;
			}
		}
		return !$p['bool'](error);
	};
	$m['validateInteger']['__name__'] = 'validateInteger';

	$m['validateInteger']['__bind_type__'] = 0;
	$m['validateInteger']['__args__'] = [null,null,['tbs']];
	$m['ValidatingFieldsChangeListener'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('onChange', function(widget) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				widget = arguments[1];
			}

			widget['removeStyleName']('validation-error');
			return null;
		}
	, 1, [null,null,['self'],['widget']]);
		$cls_definition['onChange'] = $method;
		$method = $pyjs__bind_method2('onKeyDown', function(sender, keycode, modifiers) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
				keycode = arguments[2];
				modifiers = arguments[3];
			}

			sender['removeStyleName']('validation-error');
			return null;
		}
	, 1, [null,null,['self'],['sender'],['keycode'],['modifiers']]);
		$cls_definition['onKeyDown'] = $method;
		$method = $pyjs__bind_method2('onKeyUp', function(sender, keycode, modifiers) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
				keycode = arguments[2];
				modifiers = arguments[3];
			}

 			return null;
		}
	, 1, [null,null,['self'],['sender'],['keycode'],['modifiers']]);
		$cls_definition['onKeyUp'] = $method;
		$method = $pyjs__bind_method2('onKeyPress', function(sender, keycode, modifiers) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
				keycode = arguments[2];
				modifiers = arguments[3];
			}

 			return null;
		}
	, 1, [null,null,['self'],['sender'],['keycode'],['modifiers']]);
		$cls_definition['onKeyPress'] = $method;
		var $bases = new Array(pyjslib['object']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('ValidatingFieldsChangeListener', $p['tuple']($bases), $data);
	})();
	$m['vfcl'] = $m['ValidatingFieldsChangeListener']();
	$m['setValidatingFields'] = function(fields) {
		var $iter3_idx,f,$iter3_nextval,$iter3_type,$iter3_iter,$iter3_array;
		$iter3_iter = fields;
		$iter3_nextval=$p['__iter_prepare']($iter3_iter,false);
		while (typeof($p['__wrapped_next']($iter3_nextval)['$nextval']) != 'undefined') {
			f = $iter3_nextval['$nextval'];
			f['addChangeListener']($m['vfcl']);
			f['addKeyboardListener']($m['vfcl']);
		}
		return null;
	};
	$m['setValidatingFields']['__name__'] = 'setValidatingFields';

	$m['setValidatingFields']['__bind_type__'] = 0;
	$m['setValidatingFields']['__args__'] = [null,null,['fields']];
	$m['emptyFields'] = function(fields) {
		var f,$iter4_idx,$iter4_type,$iter4_nextval,$iter4_array,$iter4_iter;
		$iter4_iter = fields;
		$iter4_nextval=$p['__iter_prepare']($iter4_iter,false);
		while (typeof($p['__wrapped_next']($iter4_nextval)['$nextval']) != 'undefined') {
			f = $iter4_nextval['$nextval'];
			f['setText']('');
		}
		return null;
	};
	$m['emptyFields']['__name__'] = 'emptyFields';

	$m['emptyFields']['__bind_type__'] = 0;
	$m['emptyFields']['__args__'] = [null,null,['fields']];
	$m['DataButton'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(html, callback, data) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				html = arguments[1];
				callback = arguments[2];
				data = arguments[3];
			}

			$m['Button']['__init__'](self, html, $p['getattr'](self, 'onButton'));
			self['data'] = data;
			self['callback'] = callback;
			return null;
		}
	, 1, [null,null,['self'],['html'],['callback'],['data']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onButton', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			self['callback'](self, $p['getattr'](self, 'data'));
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['onButton'] = $method;
		var $bases = new Array($m['Button']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('DataButton', $p['tuple']($bases), $data);
	})();
	$m['QuestionDialogBox'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(title, question, answers) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				title = arguments[1];
				question = arguments[2];
				answers = arguments[3];
			}
			var $iter5_nextval,$iter5_array,$iter5_iter,$iter5_type,contents,buttons,$iter5_idx,$sub3,$sub2,$sub1,$sub4,db,$div2,$div3,$div1,$div4,a,$add2,$add3,$add1,$add4,top,left;
			$pyjs_kwargs_call($m['DialogBox'], '__init__', null, null, [{'glass':true}, self]);
			contents = $pyjs_kwargs_call(null, $m['VerticalPanel'], null, null, [{'StyleName':'Contents', 'Spacing':4}]);
			contents['add']($m['HTML'](question));
			buttons = $m['HorizontalPanel']();
			contents['add'](buttons);
			contents['setCellWidth'](buttons, '100%');
			contents['setCellHorizontalAlignment'](buttons, $p['getattr']($m['HasAlignment'], 'ALIGN_RIGHT'));
			$iter5_iter = answers;
			$iter5_nextval=$p['__iter_prepare']($iter5_iter,false);
			while (typeof($p['__wrapped_next']($iter5_nextval)['$nextval']) != 'undefined') {
				a = $iter5_nextval['$nextval'];
				db = $m['DataButton'](a['__getitem__'](0), $p['getattr'](self, 'onButton'), $p['tuple']([a['__getitem__'](1), a['__getitem__'](2)]));
				buttons['add'](db);
			}
			self['setHTML']($p['sprintf']('<b>%s</b>', title));
			self['setWidget'](contents);
			left = $p['__op_add']($add1=(typeof ($div1=$p['__op_sub']($sub1=$m['Window']['getClientWidth'](),$sub2=200))==typeof ($div2=2) && typeof $div1=='number' && $div2 !== 0?
				$div1/$div2:
				$p['op_div']($div1,$div2)),$add2=$m['Window']['getScrollLeft']());
			top = $p['__op_add']($add3=(typeof ($div3=$p['__op_sub']($sub3=$m['Window']['getClientHeight'](),$sub4=100))==typeof ($div4=2) && typeof $div3=='number' && $div4 !== 0?
				$div3/$div4:
				$p['op_div']($div3,$div4)),$add4=$m['Window']['getScrollTop']());
			self['setPopupPosition'](left, top);
			return null;
		}
	, 1, [null,null,['self'],['title'],['question'],['answers']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onButton', function(button, data) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				button = arguments[1];
				data = arguments[2];
			}
			var callback;
			self['hide']();
			callback = data['__getitem__'](0);
			if ($p['bool']((callback !== null))) {
				callback(data['__getitem__'](1));
			}
			return null;
		}
	, 1, [null,null,['self'],['button'],['data']]);
		$cls_definition['onButton'] = $method;
		var $bases = new Array($m['DialogBox']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('QuestionDialogBox', $p['tuple']($bases), $data);
	})();
	$m['HourListBox'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}
			var $iter6_idx,$iter6_type,h,$iter6_array,$iter6_iter,ora,$iter6_nextval;
			$m['ListBox']['__init__'](self);
			$iter6_iter = $p['range'](0, 24);
			$iter6_nextval=$p['__iter_prepare']($iter6_iter,false);
			while (typeof($p['__wrapped_next']($iter6_nextval)['$nextval']) != 'undefined') {
				h = $iter6_nextval['$nextval'];
				ora = $p['sprintf']('%02d', h);
				self['addItem'](ora, ora);
			}
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('selectValue', function(v) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				v = arguments[1];
			}

			v = $p['sprintf']('%02d', $p['float_int'](v));
			return $m['ListBox']['selectValue'](self, v);
		}
	, 1, [null,null,['self'],['v']]);
		$cls_definition['selectValue'] = $method;
		var $bases = new Array($m['ListBox']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('HourListBox', $p['tuple']($bases), $data);
	})();
	$m['MinuteListBox'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}
			var $iter7_nextval,$iter7_iter,$iter7_array,m,minuto,$iter7_idx,$iter7_type;
			$m['ListBox']['__init__'](self);
			$iter7_iter = $p['range'](0, 60, 5);
			$iter7_nextval=$p['__iter_prepare']($iter7_iter,false);
			while (typeof($p['__wrapped_next']($iter7_nextval)['$nextval']) != 'undefined') {
				m = $iter7_nextval['$nextval'];
				minuto = $p['sprintf']('%02d', m);
				self['addItem'](minuto, minuto);
			}
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('selectValue', function(v) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				v = arguments[1];
			}

			v = $p['sprintf']('%02d', $p['float_int'](v));
			return $m['ListBox']['selectValue'](self, v);
		}
	, 1, [null,null,['self'],['v']]);
		$cls_definition['selectValue'] = $method;
		var $bases = new Array($m['ListBox']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('MinuteListBox', $p['tuple']($bases), $data);
	})();
	$m['MyAnchor'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
				var args = $p['tuple']($pyjs_array_slice['call'](arguments,0,arguments['length']-1));

				var kwargs = arguments['length'] >= 1 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					if (typeof kwargs != 'undefined') args['__array']['push'](kwargs);
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				var args = $p['tuple']($pyjs_array_slice['call'](arguments,1,arguments['length']-1));

				var kwargs = arguments['length'] >= 2 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					if (typeof kwargs != 'undefined') args['__array']['push'](kwargs);
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[1];
					}
				} else {
				}
			}

			$pyjs_kwargs_call($m['Anchor'], '__init__', args, kwargs, [{}, self]);
			self['my_parita'] = 0;
			self['max_parita'] = 2;
			return null;
		}
	, 1, ['args',['kwargs'],['self']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('set_numero_eventi', function(n) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				n = arguments[1];
			}

			self['max_parita'] = n;
			return null;
		}
	, 1, [null,null,['self'],['n']]);
		$cls_definition['set_numero_eventi'] = $method;
		$method = $pyjs__bind_method2('addClickListener', function(listener) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				listener = arguments[1];
			}

			self['my_original_listener'] = listener;
			$m['Anchor']['addClickListener'](self, $p['getattr'](self, 'myClickListener'));
			return null;
		}
	, 1, [null,null,['self'],['listener']]);
		$cls_definition['addClickListener'] = $method;
		$method = $pyjs__bind_method2('myClickListener', function(source) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				source = arguments[1];
			}
			var $add6,$add5;
			self['my_parita'] = $p['__op_add']($add5=$p['getattr'](self, 'my_parita'),$add6=1);
			if ($p['bool'](((($p['cmp']($p['getattr'](self, 'my_parita'), $p['getattr'](self, 'max_parita')))|1) == 1))) {
				self['my_parita'] = 0;
				self['my_original_listener'](source);
			}
			return null;
		}
	, 1, [null,null,['self'],['source']]);
		$cls_definition['myClickListener'] = $method;
		var $bases = new Array($m['Anchor']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('MyAnchor', $p['tuple']($bases), $data);
	})();
	$m['HelpButton'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(text, align_right) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				text = arguments[1];
				align_right = arguments[2];
			}
			if (typeof align_right == 'undefined') align_right=arguments['callee']['__args__'][4][1];

			$m['HorizontalPanel']['__init__'](self);
			self['img'] = $m['Image']('question.png');
			self['add']($p['getattr'](self, 'img'));
			if ($p['bool'](align_right)) {
				self['setWidth']('100%');
				self['setCellHorizontalAlignment']($p['getattr'](self, 'img'), $p['getattr']($m['HasAlignment'], 'ALIGN_RIGHT'));
			}
			self['text'] = text;
			self['img']['addClickListener']($p['getattr'](self, 'showPopup'));
			self['img']['addStyleName']('help-image');
			return null;
		}
	, 1, [null,null,['self'],['text'],['align_right', false]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('showPopup', function(event) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				event = arguments[1];
			}
			var $add9,rp,pw,top,$sub6,$sub8,$add10,$sub5,y,x,$add8,left,$sub7,contents,$add7;
			contents = $m['HTML']($p['getattr'](self, 'text'));
			contents['addClickListener']($p['getattr'](self, 'onClick'));
			self['_popup'] = $pyjs_kwargs_call(null, $m['PopupPanel'], null, null, [{'autoHide':true}]);
			self['_popup']['add'](contents);
			self['_popup']['setStyleName']('help-popup');
			rp = $m['RootPanel']();
			pw = $m['Window']['getClientWidth']();
			x = self['img']['getAbsoluteLeft']();
			y = self['img']['getAbsoluteTop']();
			left = ($p['bool'](($p['cmp']($p['__op_sub']($sub5=pw,$sub6=x), 300) == 1))? ($p['__op_add']($add7=x,$add8=10)) : ($p['__op_sub']($sub7=x,$sub8=300)));
			top = $p['__op_add']($add9=y,$add10=10);
			self['_popup']['setPopupPosition'](left, top);
			self['_popup']['show']();
			return null;
		}
	, 1, [null,null,['self'],['event']]);
		$cls_definition['showPopup'] = $method;
		$method = $pyjs__bind_method2('onClick', function(sender) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
			}
			if (typeof sender == 'undefined') sender=arguments['callee']['__args__'][3][1];

			self['_popup']['hide']();
			return null;
		}
	, 1, [null,null,['self'],['sender', null]]);
		$cls_definition['onClick'] = $method;
		var $bases = new Array($m['HorizontalPanel']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('HelpButton', $p['tuple']($bases), $data);
	})();
	$m['StyledFlexTable'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
				var args = $p['tuple']($pyjs_array_slice['call'](arguments,0,arguments['length']-1));

				var kwargs = arguments['length'] >= 1 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					if (typeof kwargs != 'undefined') args['__array']['push'](kwargs);
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				var args = $p['tuple']($pyjs_array_slice['call'](arguments,1,arguments['length']-1));

				var kwargs = arguments['length'] >= 2 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					if (typeof kwargs != 'undefined') args['__array']['push'](kwargs);
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[1];
					}
				} else {
				}
			}

			$pyjs_kwargs_call($m['FlexTable'], '__init__', args, kwargs, [{}, self]);
			self['formatter'] = $m['FlexCellFormatter'](self);
			self['setCellFormatter']($p['getattr'](self, 'formatter'));
			self['row'] = 0;
			self['column'] = 0;
			return null;
		}
	, 1, ['args',['kwargs'],['self']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('newRow', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}
			var $add11,$add12;
			self['row'] = $p['__op_add']($add11=$p['getattr'](self, 'row'),$add12=1);
			self['column'] = 0;
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['newRow'] = $method;
		$method = $pyjs__bind_method2('getRow', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			return $p['getattr'](self, 'row');
		}
	, 1, [null,null,['self']]);
		$cls_definition['getRow'] = $method;
		$method = $pyjs__bind_method2('addStyledWidget', function(w, style, center, expand) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				w = arguments[1];
				style = arguments[2];
				center = arguments[3];
				expand = arguments[4];
			}
			if (typeof style == 'undefined') style=arguments['callee']['__args__'][4][1];
			if (typeof center == 'undefined') center=arguments['callee']['__args__'][5][1];
			if (typeof expand == 'undefined') expand=arguments['callee']['__args__'][6][1];
			var $add14,$add13;
			self['setWidget']($p['getattr'](self, 'row'), $p['getattr'](self, 'column'), w);
			if ($p['bool']((style !== null))) {
				self['formatter']['addStyleName']($p['getattr'](self, 'row'), $p['getattr'](self, 'column'), style);
			}
			if ($p['bool'](center)) {
				self['formatter']['setHorizontalAlignment']($p['getattr'](self, 'row'), $p['getattr'](self, 'column'), $p['getattr']($m['HasAlignment'], 'ALIGN_CENTER'));
			}
			if ($p['bool'](expand)) {
				self['formatter']['setWidth']($p['getattr'](self, 'row'), $p['getattr'](self, 'column'), '100%');
				w['setWidth']('100%');
			}
			self['column'] = $p['__op_add']($add13=$p['getattr'](self, 'column'),$add14=1);
			return null;
		}
	, 1, [null,null,['self'],['w'],['style', null],['center', false],['expand', false]]);
		$cls_definition['addStyledWidget'] = $method;
		var $bases = new Array($m['FlexTable']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('StyledFlexTable', $p['tuple']($bases), $data);
	})();
	$m['StyledFixedColumnFlexTable'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
				var args = $p['tuple']($pyjs_array_slice['call'](arguments,0,arguments['length']-1));

				var kwargs = arguments['length'] >= 1 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					if (typeof kwargs != 'undefined') args['__array']['push'](kwargs);
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				var args = $p['tuple']($pyjs_array_slice['call'](arguments,1,arguments['length']-1));

				var kwargs = arguments['length'] >= 2 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					if (typeof kwargs != 'undefined') args['__array']['push'](kwargs);
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[1];
					}
				} else {
				}
			}

			self['column_count'] = kwargs['__getitem__']('column_count');
			kwargs['__delitem__']('column_count');
			$pyjs_kwargs_call($m['StyledFlexTable'], '__init__', args, kwargs, [{}, self]);
			return null;
		}
	, 1, ['args',['kwargs'],['self']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('addStyledWidget', function(w, style, center, expand) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				w = arguments[1];
				style = arguments[2];
				center = arguments[3];
				expand = arguments[4];
			}
			if (typeof style == 'undefined') style=arguments['callee']['__args__'][4][1];
			if (typeof center == 'undefined') center=arguments['callee']['__args__'][5][1];
			if (typeof expand == 'undefined') expand=arguments['callee']['__args__'][6][1];

			$m['StyledFlexTable']['addStyledWidget'](self, w, style, center, expand);
			if ($p['bool']($p['op_eq']($p['getattr'](self, 'column'), $p['getattr'](self, 'column_count')))) {
				self['newRow']();
			}
			return null;
		}
	, 1, [null,null,['self'],['w'],['style', null],['center', false],['expand', false]]);
		$cls_definition['addStyledWidget'] = $method;
		$method = $pyjs__bind_method2('add', function(w) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				w = arguments[1];
			}

			$pyjs_kwargs_call(self, 'addStyledWidget', null, null, [{'center':true, 'expand':(typeof expand == "undefined"?$m['expand']:expand)}, w]);
			return null;
		}
	, 1, [null,null,['self'],['w']]);
		$cls_definition['add'] = $method;
		var $bases = new Array($m['StyledFlexTable']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('StyledFixedColumnFlexTable', $p['tuple']($bases), $data);
	})();
	$m['AutofitHorizontalPanel'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(owner) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				owner = arguments[1];
			}

			$m['HorizontalPanel']['__init__'](self);
			self['owner'] = owner;
			self['setWidth']('100%');
			self['owner']['add'](self);
			self['owner']['setCellWidth'](self, '100%');
			return null;
		}
	, 1, [null,null,['self'],['owner']]);
		$cls_definition['__init__'] = $method;
		var $bases = new Array($m['HorizontalPanel']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('AutofitHorizontalPanel', $p['tuple']($bases), $data);
	})();
	$m['AutofitVerticalPanel'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(owner) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				owner = arguments[1];
			}

			$m['VerticalPanel']['__init__'](self);
			self['owner'] = owner;
			self['setHeight']('100%');
			self['owner']['add'](self);
			self['owner']['setCellHeight'](self, '100%');
			return null;
		}
	, 1, [null,null,['self'],['owner']]);
		$cls_definition['__init__'] = $method;
		var $bases = new Array($m['VerticalPanel']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('AutofitVerticalPanel', $p['tuple']($bases), $data);
	})();
	$m['Autofit'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(owner) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				owner = arguments[1];
			}

			$p['object']['__init__'](self);
			self['owner'] = owner;
			self['owner']['add'](self);
			self['setSize']('100%', '100%');
			self['owner']['setCellWidth'](self, '100%');
			self['owner']['setCellHeight'](self, '100%');
			return null;
		}
	, 1, [null,null,['self'],['owner']]);
		$cls_definition['__init__'] = $method;
		var $bases = new Array($p['object']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('Autofit', $p['tuple']($bases), $data);
	})();
	$m['HTMLFlowPanel'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('setInl', function(w) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				w = arguments[1];
			}

			w['addStyleName']('inl');
			return null;
		}
	, 1, [null,null,['self'],['w']]);
		$cls_definition['setInl'] = $method;
		$method = $pyjs__bind_method2('add', function(w) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				w = arguments[1];
			}

			self['setInl'](w);
			$m['FlowPanel']['add'](self, w);
			return null;
		}
	, 1, [null,null,['self'],['w']]);
		$cls_definition['add'] = $method;
		$method = $pyjs__bind_method2('addHtml', function(html) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				html = arguments[1];
			}

			self['add']($m['HTML'](html));
			return null;
		}
	, 1, [null,null,['self'],['html']]);
		$cls_definition['addHtml'] = $method;
		$method = $pyjs__bind_method2('addBr', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			$m['FlowPanel']['add'](self, $m['HTML'](''));
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['addBr'] = $method;
		$method = $pyjs__bind_method2('addAnchor', function(text, callback) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				text = arguments[1];
				callback = arguments[2];
			}
			var a,h;
			a = $m['MyAnchor']();
			h = $m['HTML'](text);
			self['setInl'](h);
			a['setWidget'](h);
			a['addClickListener'](callback);
			self['add'](a);
			return null;
		}
	, 1, [null,null,['self'],['text'],['callback']]);
		$cls_definition['addAnchor'] = $method;
		var $bases = new Array($m['FlowPanel']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('HTMLFlowPanel', $p['tuple']($bases), $data);
	})();
	$m['HidingPanel'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}
			var hp;
			$m['HorizontalPanel']['__init__'](self);
			self['content_panel'] = $m['SimplePanel']();
			self['content_panel']['setSize']('300px', '100%');
			$m['HorizontalPanel']['add'](self, $p['getattr'](self, 'content_panel'));
			hp = $m['HorizontalPanel']();
			hp['setSize']('5px', '100%');
			hp['addStyleName']('hiding-splitter');
			$m['HorizontalPanel']['add'](self, hp);
			self['setCellWidth'](hp, '5px');
			self['hider_panel'] = $m['MyAnchor']();
			hp['add']($p['getattr'](self, 'hider_panel'));
			self['hider_panel']['addClickListener']($p['getattr'](self, 'onHider'));
			self['hider_panel']['setSize']('5px', '100%');
			hp['setCellWidth']($p['getattr'](self, 'hider_panel'), '5px');
			self['hider_panel']['addStyleName']('hidePanel');
			self['setCellWidth']($p['getattr'](self, 'content_panel'), '100%');
			self['hider_panel']['set_numero_eventi'](1);
			self['open_label'] = $m['MyAnchor']();
			self['html_open_label'] = $m['HTML']('&nbsp;&laquo;&nbsp;');
			self['open_label']['setWidget']($p['getattr'](self, 'html_open_label'));
			self['html_open_label']['addStyleName']('hiding-label-html');
			hp['add']($p['getattr'](self, 'open_label'));
			self['open_label']['addStyleName']('hiding-label');
			self['open_label']['addClickListener']($p['getattr'](self, 'onHider'));
			self['is_open'] = true;
			self['hide_listener'] = null;
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('addHideListener', function(listener) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				listener = arguments[1];
			}

			self['hide_listener'] = listener;
			return null;
		}
	, 1, [null,null,['self'],['listener']]);
		$cls_definition['addHideListener'] = $method;
		$method = $pyjs__bind_method2('add', function(widget) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				widget = arguments[1];
			}

			self['w'] = widget;
			self['content_panel']['add'](widget);
			return null;
		}
	, 1, [null,null,['self'],['widget']]);
		$cls_definition['add'] = $method;
		$method = $pyjs__bind_method2('update', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			self['content_panel']['setVisible']($p['getattr'](self, 'is_open'));
			if ($p['bool']($p['getattr'](self, 'is_open'))) {
				self['html_open_label']['setHTML']('&nbsp;&laquo;&nbsp;');
			}
			else {
				self['html_open_label']['setHTML']('&nbsp;&raquo;&nbsp;');
			}
			if ($p['bool'](($p['getattr'](self, 'hide_listener') !== null))) {
				self['hide_listener'](self);
			}
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['update'] = $method;
		$method = $pyjs__bind_method2('onHider', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			self['is_open'] = !$p['bool']($p['getattr'](self, 'is_open'));
			self['update']();
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['onHider'] = $method;
		$method = $pyjs__bind_method2('hide', function(hide) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				hide = arguments[1];
			}
			if (typeof hide == 'undefined') hide=arguments['callee']['__args__'][3][1];

			self['is_open'] = !$p['bool'](hide);
			self['update']();
			return null;
		}
	, 1, [null,null,['self'],['hide', true]]);
		$cls_definition['hide'] = $method;
		var $bases = new Array($m['HorizontalPanel']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('HidingPanel', $p['tuple']($bases), $data);
	})();
	$m['AutoLayout'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(owner, sub, add_to_owner) {
			if (this['__is_instance__'] === true) {
				var self = this;
				var kwargs = arguments['length'] >= 4 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				owner = arguments[1];
				sub = arguments[2];
				add_to_owner = arguments[3];
				var kwargs = arguments['length'] >= 5 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof add_to_owner != 'undefined') {
					if (add_to_owner !== null && typeof add_to_owner['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = add_to_owner;
						add_to_owner = arguments[4];
					}
				} else 				if (typeof sub != 'undefined') {
					if (sub !== null && typeof sub['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = sub;
						sub = arguments[4];
					}
				} else 				if (typeof owner != 'undefined') {
					if (owner !== null && typeof owner['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = owner;
						owner = arguments[4];
					}
				} else 				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[4];
					}
				} else {
				}
			}
			if (typeof sub == 'undefined') sub=arguments['callee']['__args__'][4][1];
			if (typeof add_to_owner == 'undefined') add_to_owner=arguments['callee']['__args__'][5][1];
			var el,$iter8_iter,reserved_args,res,call,$iter11_idx,$and3,$iter8_idx,$iter11_iter,$iter8_type,args,$and4,$add15,$add16,$iter8_nextval,$iter11_array,$iter11_nextval,f,$iter11_type,$iter8_array,l,klass;
			self['owner'] = owner;
			self['sub'] = $p['list']([]);
			self['dict'] = $p['dict']([]);
			reserved_args = $p['__op_add']($add15=$p['list'](['class', 'name', 'args', 'style', 'enabled', 'checked', 'click_listener', 'client_data']),$add16=self['getReservedArgs']());
			$iter8_iter = sub;
			$iter8_nextval=$p['__iter_prepare']($iter8_iter,false);
			while (typeof($p['__wrapped_next']($iter8_nextval)['$nextval']) != 'undefined') {
				l = $iter8_nextval['$nextval'];
				klass = l['__getitem__']('class');
				res = $p['dict'](function(){
					var $iter9_iter,$and1,$and2,$iter9_nextval,$iter9_idx,$collcomp1,$iter9_type,x,$iter9_array;
	$collcomp1 = $p['list']();
				$iter9_iter = l;
				$iter9_nextval=$p['__iter_prepare']($iter9_iter,false);
				while (typeof($p['__wrapped_next']($iter9_nextval)['$nextval']) != 'undefined') {
					x = $iter9_nextval['$nextval'];
					if ($p['bool'](($p['bool']($and1=!reserved_args['__contains__'](x))?!$p['op_eq']($p['__getslice'](x, 0, 5), 'call_'):$and1))) {
						$collcomp1['append']($p['tuple']([x, l['__getitem__'](x)]));
					}
				}

	return $collcomp1;}());
				call = $p['dict'](function(){
					var $iter10_nextval,$iter10_idx,$collcomp2,$iter10_array,$iter10_type,x,$iter10_iter;
	$collcomp2 = $p['list']();
				$iter10_iter = l;
				$iter10_nextval=$p['__iter_prepare']($iter10_iter,false);
				while (typeof($p['__wrapped_next']($iter10_nextval)['$nextval']) != 'undefined') {
					x = $iter10_nextval['$nextval'];
					if ($p['bool']($p['op_eq']($p['__getslice'](x, 0, 5), 'call_'))) {
						$collcomp2['append']($p['tuple']([$p['__getslice'](x, 5, null), l['__getitem__'](x)]));
					}
				}

	return $collcomp2;}());
				args = $p['list']([]);
				if ($p['bool']($p['issubclass'](klass, $m['AutoLayout']))) {
					args['append'](self);
				}
				if ($p['bool'](l['__contains__']('args'))) {
					args['extend'](l['__getitem__']('args'));
				}
				el = $pyjs_kwargs_call(null, klass, args, res, [{}]);
				if ($p['bool'](l['__contains__']('style'))) {
					el['addStyleName'](l['__getitem__']('style'));
				}
				if ($p['bool'](l['__contains__']('enabled'))) {
					el['setEnabled'](l['__getitem__']('enabled'));
				}
				if ($p['bool'](l['__contains__']('checked'))) {
					el['setChecked'](l['__getitem__']('checked'));
				}
				if ($p['bool'](l['__contains__']('click_listener'))) {
					el['addClickListener'](l['__getitem__']('click_listener'));
				}
				if ($p['bool'](l['__contains__']('client_data'))) {
					l['client_data'] = l['__getitem__']('client_data');
				}
				$iter11_iter = call;
				$iter11_nextval=$p['__iter_prepare']($iter11_iter,false);
				while (typeof($p['__wrapped_next']($iter11_nextval)['$nextval']) != 'undefined') {
					f = $iter11_nextval['$nextval'];
					$pyjs_kwargs_call(null, $p['getattr'](el, f), call['__getitem__'](f)['__getitem__'](0), call['__getitem__'](f)['__getitem__'](1), [{}]);
				}
				self['onCreate'](el, l);
				self['sub']['append'](el);
				if ($p['bool'](l['__contains__']('name'))) {
					$p['getattr'](self, 'dict')['__setitem__'](l['__getitem__']('name'), el);
				}
			}
			if ($p['bool'](($p['bool']($and3=(owner !== null))?add_to_owner:$and3))) {
				owner['add'](self);
			}
			return null;
		}
	, 1, [null,['kwargs'],['self'],['owner'],['sub', $p['list']([])],['add_to_owner', false]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onCreate', function(el, kwargs) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				el = arguments[1];
				kwargs = arguments[2];
			}

			el['setSize']('100%', '100%');
			self['add'](el);
			return null;
		}
	, 1, [null,null,['self'],['el'],['kwargs']]);
		$cls_definition['onCreate'] = $method;
		$method = $pyjs__bind_method2('getReservedArgs', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			return $p['list']([]);
		}
	, 1, [null,null,['self']]);
		$cls_definition['getReservedArgs'] = $method;
		$method = $pyjs__bind_method2('by_name', function(name) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				name = arguments[1];
			}
			var el,$iter12_type,$iter12_array,$iter12_nextval,$iter12_iter,s,$iter12_idx;
			if ($p['bool']($p['getattr'](self, 'dict')['__contains__'](name))) {
				return $p['getattr'](self, 'dict')['__getitem__'](name);
			}
			$iter12_iter = $p['getattr'](self, 'sub');
			$iter12_nextval=$p['__iter_prepare']($iter12_iter,false);
			while (typeof($p['__wrapped_next']($iter12_nextval)['$nextval']) != 'undefined') {
				s = $iter12_nextval['$nextval'];
				if ($p['bool']($p['isinstance'](s, $m['AutoLayout']))) {
					el = s['by_name'](name);
					if ($p['bool']((el !== null))) {
						return el;
					}
				}
			}
			return null;
		}
	, 1, [null,null,['self'],['name']]);
		$cls_definition['by_name'] = $method;
		$method = $pyjs__bind_method2('__getitem__', function(name) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				name = arguments[1];
			}

			return self['by_name'](name);
		}
	, 1, [null,null,['self'],['name']]);
		$cls_definition['__getitem__'] = $method;
		var $bases = new Array(pyjslib['object']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('AutoLayout', $p['tuple']($bases), $data);
	})();
	$m['HP'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(owner, sub) {
			if (this['__is_instance__'] === true) {
				var self = this;
				var kwargs = arguments['length'] >= 3 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				owner = arguments[1];
				sub = arguments[2];
				var kwargs = arguments['length'] >= 4 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof sub != 'undefined') {
					if (sub !== null && typeof sub['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = sub;
						sub = arguments[3];
					}
				} else 				if (typeof owner != 'undefined') {
					if (owner !== null && typeof owner['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = owner;
						owner = arguments[3];
					}
				} else 				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[3];
					}
				} else {
				}
			}
			if (typeof sub == 'undefined') sub=arguments['callee']['__args__'][4][1];

			$m['HorizontalPanel']['__init__'](self);
			$pyjs_kwargs_call($m['AutoLayout'], '__init__', null, kwargs, [{}, self, owner, sub]);
			self['setHeight']('100%');
			return null;
		}
	, 1, [null,['kwargs'],['self'],['owner'],['sub', $p['list']([])]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onCreate', function(el, kwargs) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				el = arguments[1];
				kwargs = arguments[2];
			}

			el['setWidth']('100%');
			self['add'](el);
			if ($p['bool'](kwargs['__contains__']('width'))) {
				if ($p['bool']((kwargs['__getitem__']('width') !== null))) {
					self['setCellWidth'](el, kwargs['__getitem__']('width'));
				}
			}
			if ($p['bool'](!$p['bool'](kwargs['__contains__']('height')))) {
				self['setCellHeight'](el, '100%');
			}
			else if ($p['bool']((kwargs['__getitem__']('height') !== null))) {
				self['setCellHeight'](el, kwargs['__getitem__']('height'));
			}
			if ($p['bool'](kwargs['__contains__']('vertical_alignment'))) {
				self['setCellVerticalAlignment'](el, kwargs['__getitem__']('vertical_alignment'));
			}
			return null;
		}
	, 1, [null,null,['self'],['el'],['kwargs']]);
		$cls_definition['onCreate'] = $method;
		$method = $pyjs__bind_method2('getReservedArgs', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			return $p['list'](['width', 'vertical_alignment']);
		}
	, 1, [null,null,['self']]);
		$cls_definition['getReservedArgs'] = $method;
		var $bases = new Array($m['HorizontalPanel'],$m['AutoLayout']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('HP', $p['tuple']($bases), $data);
	})();
	$m['VP'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(owner, sub) {
			if (this['__is_instance__'] === true) {
				var self = this;
				var kwargs = arguments['length'] >= 3 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				owner = arguments[1];
				sub = arguments[2];
				var kwargs = arguments['length'] >= 4 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof sub != 'undefined') {
					if (sub !== null && typeof sub['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = sub;
						sub = arguments[3];
					}
				} else 				if (typeof owner != 'undefined') {
					if (owner !== null && typeof owner['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = owner;
						owner = arguments[3];
					}
				} else 				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[3];
					}
				} else {
				}
			}
			if (typeof sub == 'undefined') sub=arguments['callee']['__args__'][4][1];

			$m['VerticalPanel']['__init__'](self);
			$pyjs_kwargs_call($m['AutoLayout'], '__init__', null, kwargs, [{}, self, owner, sub]);
			self['setWidth']('100%');
			return null;
		}
	, 1, [null,['kwargs'],['self'],['owner'],['sub', $p['list']([])]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onCreate', function(el, kwargs) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				el = arguments[1];
				kwargs = arguments[2];
			}

			if ($p['bool'](!$p['bool'](kwargs['__contains__']('width')))) {
				el['setWidth']('100%');
			}
			else if ($p['bool']((kwargs['__getitem__']('width') !== null))) {
				el['setWidth'](kwargs['__getitem__']('width'));
			}
			self['add'](el);
			if ($p['bool'](kwargs['__contains__']('height'))) {
				if ($p['bool']((kwargs['__getitem__']('height') !== null))) {
					self['setCellHeight'](el, kwargs['__getitem__']('height'));
					el['setHeight']('100%');
				}
			}
			else {
				self['setCellHeight'](el, '100%');
				el['setHeight']('100%');
			}
			self['setCellWidth'](el, '100%');
			if ($p['bool'](kwargs['__contains__']('horizontal_alignment'))) {
				self['setCellHorizontalAlignment'](el, kwargs['__getitem__']('horizontal_alignment'));
			}
			return null;
		}
	, 1, [null,null,['self'],['el'],['kwargs']]);
		$cls_definition['onCreate'] = $method;
		$method = $pyjs__bind_method2('getReservedArgs', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			return $p['list'](['height', 'width', 'horizontal_alignment']);
		}
	, 1, [null,null,['self']]);
		$cls_definition['getReservedArgs'] = $method;
		var $bases = new Array($m['VerticalPanel'],$m['AutoLayout']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('VP', $p['tuple']($bases), $data);
	})();
	$m['DP'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(owner, sub) {
			if (this['__is_instance__'] === true) {
				var self = this;
				var kwargs = arguments['length'] >= 3 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				owner = arguments[1];
				sub = arguments[2];
				var kwargs = arguments['length'] >= 4 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof sub != 'undefined') {
					if (sub !== null && typeof sub['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = sub;
						sub = arguments[3];
					}
				} else 				if (typeof owner != 'undefined') {
					if (owner !== null && typeof owner['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = owner;
						owner = arguments[3];
					}
				} else 				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[3];
					}
				} else {
				}
			}
			if (typeof sub == 'undefined') sub=arguments['callee']['__args__'][4][1];

			$m['DisclosurePanel']['__init__'](self, kwargs['__getitem__']('title'));
			$pyjs_kwargs_call($m['AutoLayout'], '__init__', null, kwargs, [{}, self, owner, sub]);
			self['setWidth']('100%');
			self['setOpen'](true);
			return null;
		}
	, 1, [null,['kwargs'],['self'],['owner'],['sub', $p['list']([])]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('getReservedArgs', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			return $p['list'](['height']);
		}
	, 1, [null,null,['self']]);
		$cls_definition['getReservedArgs'] = $method;
		var $bases = new Array($m['DisclosurePanel'],$m['AutoLayout']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('DP', $p['tuple']($bases), $data);
	})();
	$m['SP'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(owner, sub) {
			if (this['__is_instance__'] === true) {
				var self = this;
				var kwargs = arguments['length'] >= 3 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				owner = arguments[1];
				sub = arguments[2];
				var kwargs = arguments['length'] >= 4 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof sub != 'undefined') {
					if (sub !== null && typeof sub['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = sub;
						sub = arguments[3];
					}
				} else 				if (typeof owner != 'undefined') {
					if (owner !== null && typeof owner['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = owner;
						owner = arguments[3];
					}
				} else 				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[3];
					}
				} else {
				}
			}
			if (typeof sub == 'undefined') sub=arguments['callee']['__args__'][4][1];

			$m['SimplePanel']['__init__'](self);
			$pyjs_kwargs_call($m['AutoLayout'], '__init__', null, kwargs, [{}, self, owner, sub]);
			self['setWidth']('100%');
			return null;
		}
	, 1, [null,['kwargs'],['self'],['owner'],['sub', $p['list']([])]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('getReservedArgs', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			return $p['list'](['height']);
		}
	, 1, [null,null,['self']]);
		$cls_definition['getReservedArgs'] = $method;
		var $bases = new Array($m['SimplePanel'],$m['AutoLayout']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('SP', $p['tuple']($bases), $data);
	})();
	$m['GP'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(owner, sub) {
			if (this['__is_instance__'] === true) {
				var self = this;
				var kwargs = arguments['length'] >= 3 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				owner = arguments[1];
				sub = arguments[2];
				var kwargs = arguments['length'] >= 4 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof sub != 'undefined') {
					if (sub !== null && typeof sub['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = sub;
						sub = arguments[3];
					}
				} else 				if (typeof owner != 'undefined') {
					if (owner !== null && typeof owner['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = owner;
						owner = arguments[3];
					}
				} else 				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[3];
					}
				} else {
				}
			}
			if (typeof sub == 'undefined') sub=arguments['callee']['__args__'][4][1];

			$pyjs_kwargs_call($m['StyledFixedColumnFlexTable'], '__init__', null, null, [{'column_count':kwargs['__getitem__']('column_count')}, self]);
			$pyjs_kwargs_call($m['AutoLayout'], '__init__', null, kwargs, [{}, self, owner, sub]);
			self['setWidth']('100%');
			return null;
		}
	, 1, [null,['kwargs'],['self'],['owner'],['sub', $p['list']([])]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onCreate', function(el, kwargs) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				el = arguments[1];
				kwargs = arguments[2];
			}
			var expand;
			expand = true;
			if ($p['bool'](kwargs['__contains__']('expand'))) {
				expand = kwargs['__getitem__']('expand');
			}
			$pyjs_kwargs_call(self, 'addStyledWidget', null, null, [{'expand':expand}, el]);
			return null;
		}
	, 1, [null,null,['self'],['el'],['kwargs']]);
		$cls_definition['onCreate'] = $method;
		$method = $pyjs__bind_method2('getReservedArgs', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			return $p['list'](['expand']);
		}
	, 1, [null,null,['self']]);
		$cls_definition['getReservedArgs'] = $method;
		var $bases = new Array($m['StyledFixedColumnFlexTable'],$m['AutoLayout']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('GP', $p['tuple']($bases), $data);
	})();
	$m['get_checked_radio'] = function(base, name, values) {
		var $iter13_nextval,$iter13_iter,$iter13_array,$iter13_idx,v,$iter13_type;
		$iter13_iter = values;
		$iter13_nextval=$p['__iter_prepare']($iter13_iter,false);
		while (typeof($p['__wrapped_next']($iter13_nextval)['$nextval']) != 'undefined') {
			v = $iter13_nextval['$nextval'];
			if ($p['bool'](base['by_name']($p['sprintf']('%s_%s', $p['tuple']([name, $p['str'](v)])))['isChecked']())) {
				return v;
			}
		}
		return null;
	};
	$m['get_checked_radio']['__name__'] = 'get_checked_radio';

	$m['get_checked_radio']['__bind_type__'] = 0;
	$m['get_checked_radio']['__args__'] = [null,null,['base'],['name'],['values']];
	$m['ValidationErrorRemover'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(widget) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				widget = arguments[1];
			}

			self['widget'] = widget;
			return null;
		}
	, 1, [null,null,['self'],['widget']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onKeyDown', function(sender, keycode, modifiers) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
				keycode = arguments[2];
				modifiers = arguments[3];
			}

			self['widget']['removeStyleName']('validation-error');
			return null;
		}
	, 1, [null,null,['self'],['sender'],['keycode'],['modifiers']]);
		$cls_definition['onKeyDown'] = $method;
		$method = $pyjs__bind_method2('remove', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			self['widget']['removeStyleName']('validation-error');
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['remove'] = $method;
		var $bases = new Array($m['KeyboardHandler']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('ValidationErrorRemover', $p['tuple']($bases), $data);
	})();
	$m['LoadingButton'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
				var args = $p['tuple']($pyjs_array_slice['call'](arguments,0,arguments['length']-1));

				var kwargs = arguments['length'] >= 1 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					if (typeof kwargs != 'undefined') args['__array']['push'](kwargs);
					var kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			} else {
				var self = arguments[0];
				var args = $p['tuple']($pyjs_array_slice['call'](arguments,1,arguments['length']-1));

				var kwargs = arguments['length'] >= 2 ? arguments[arguments['length']-1] : arguments[arguments['length']];
				if (kwargs === null || typeof kwargs != 'object' || kwargs['__name__'] != 'dict' || typeof kwargs['$pyjs_is_kwarg'] == 'undefined') {
					if (typeof kwargs != 'undefined') args['__array']['push'](kwargs);
					kwargs = arguments[arguments['length']+1];
				} else {
					delete kwargs['$pyjs_is_kwarg'];
				}
			}
			if (typeof kwargs == 'undefined') {
				kwargs = $p['__empty_dict']();
				if (typeof self != 'undefined') {
					if (self !== null && typeof self['$pyjs_is_kwarg'] != 'undefined') {
						kwargs = self;
						self = arguments[1];
					}
				} else {
				}
			}

			$pyjs_kwargs_call($m['Button'], '__init__', args, kwargs, [{}, self]);
			self['backup_html'] = null;
			return null;
		}
	, 1, ['args',['kwargs'],['self']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('start', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			if ($p['bool'](($p['getattr'](self, 'backup_html') === null))) {
				self['setEnabled'](false);
				self['backup_html'] = self['getHTML']();
				self['setHTML']('<img src="loading.gif" />');
			}
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['start'] = $method;
		$method = $pyjs__bind_method2('stop', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			if ($p['bool'](($p['getattr'](self, 'backup_html') !== null))) {
				self['setHTML']($p['getattr'](self, 'backup_html'));
				self['backup_html'] = null;
				self['setEnabled'](true);
			}
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['stop'] = $method;
		var $bases = new Array($m['Button']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('LoadingButton', $p['tuple']($bases), $data);
	})();
	$m['MenuCmd'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(handler) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				handler = arguments[1];
			}

			self['handler'] = handler;
			return null;
		}
	, 1, [null,null,['self'],['handler']]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('execute', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			self['handler']();
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['execute'] = $method;
		var $bases = new Array(pyjslib['object']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('MenuCmd', $p['tuple']($bases), $data);
	})();
	$m['ToggleImage'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(filename, style_inactive, style_active, callback, data, can_turn_off) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				filename = arguments[1];
				style_inactive = arguments[2];
				style_active = arguments[3];
				callback = arguments[4];
				data = arguments[5];
				can_turn_off = arguments[6];
			}
			if (typeof callback == 'undefined') callback=arguments['callee']['__args__'][6][1];
			if (typeof data == 'undefined') data=arguments['callee']['__args__'][7][1];
			if (typeof can_turn_off == 'undefined') can_turn_off=arguments['callee']['__args__'][8][1];

			$m['Image']['__init__'](self, filename);
			self['style_inactive'] = style_inactive;
			self['style_active'] = style_active;
			self['callback'] = callback;
			self['active'] = false;
			self['setActive'](false);
			self['addClickListener']($p['getattr'](self, 'onClick'));
			self['data'] = data;
			self['can_turn_off'] = can_turn_off;
			return null;
		}
	, 1, [null,null,['self'],['filename'],['style_inactive'],['style_active'],['callback', null],['data', null],['can_turn_off', true]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('setActive', function(active) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				active = arguments[1];
			}
			if (typeof active == 'undefined') active=arguments['callee']['__args__'][3][1];

			if ($p['bool']((active === null))) {
				active = !$p['bool']($p['getattr'](self, 'active'));
			}
			self['active'] = active;
			if ($p['bool'](!$p['bool'](active))) {
				self['removeStyleName']($p['getattr'](self, 'style_active'));
				self['addStyleName']($p['getattr'](self, 'style_inactive'));
			}
			else {
				self['removeStyleName']($p['getattr'](self, 'style_inactive'));
				self['addStyleName']($p['getattr'](self, 'style_active'));
			}
			return null;
		}
	, 1, [null,null,['self'],['active', null]]);
		$cls_definition['setActive'] = $method;
		$method = $pyjs__bind_method2('isActive', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			return $p['getattr'](self, 'active');
		}
	, 1, [null,null,['self']]);
		$cls_definition['isActive'] = $method;
		$method = $pyjs__bind_method2('onClick', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			if ($p['bool']($p['getattr'](self, 'can_turn_off'))) {
				self['setActive']();
			}
			else if ($p['bool'](!$p['bool']($p['getattr'](self, 'active')))) {
				self['setActive'](true);
			}
			if ($p['bool'](($p['getattr'](self, 'callback') !== null))) {
				self['callback'](self);
			}
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['onClick'] = $method;
		var $bases = new Array($m['Image']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('ToggleImage', $p['tuple']($bases), $data);
	})();
	$m['SearchPopup'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(els, callback, textbox) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				els = arguments[1];
				callback = arguments[2];
				textbox = arguments[3];
			}
			if (typeof textbox == 'undefined') textbox=arguments['callee']['__args__'][5][1];
			var el,$iter14_array,$iter14_type,name,$iter14_iter,pk,$iter14_nextval,$iter14_idx;
			$pyjs_kwargs_call($m['PopupPanel'], '__init__', null, null, [{'modal':false}, self, true]);
			self['callback'] = callback;
			self['list'] = $m['ListBox']();
			self['list']['setVisibleItemCount'](10);
			self['list']['addClickListener']($p['getattr'](self, 'onList'));
			self['els'] = els;
			self['names'] = $p['dict']([]);
			$iter14_iter = els;
			$iter14_nextval=$p['__iter_prepare']($iter14_iter,false);
			while (typeof($p['__wrapped_next']($iter14_nextval)['$nextval']) != 'undefined') {
				el = $iter14_nextval['$nextval'];
				var $tupleassign1 = $p['__ass_unpack'](el, 2, null);
				pk = $tupleassign1[0];
				name = $tupleassign1[1];
				self['list']['addItem'](name, pk);
				$p['getattr'](self, 'names')['__setitem__'](pk, name);
			}
			self['setWidget']($p['getattr'](self, 'list'));
			self['list']['addKeyboardListener'](self);
			self['textbox'] = textbox;
			return null;
		}
	, 1, [null,null,['self'],['els'],['callback'],['textbox', null]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('update', function(els) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				els = arguments[1];
			}
			var el,$iter15_iter,$iter15_array,$iter15_idx,$iter15_nextval,$iter15_type,pk,name;
			self['list']['clear']();
			self['names'] = $p['dict']([]);
			$iter15_iter = els;
			$iter15_nextval=$p['__iter_prepare']($iter15_iter,false);
			while (typeof($p['__wrapped_next']($iter15_nextval)['$nextval']) != 'undefined') {
				el = $iter15_nextval['$nextval'];
				var $tupleassign2 = $p['__ass_unpack'](el, 2, null);
				pk = $tupleassign2[0];
				name = $tupleassign2[1];
				self['list']['addItem'](name, pk);
				$p['getattr'](self, 'names')['__setitem__'](pk, name);
			}
			return null;
		}
	, 1, [null,null,['self'],['els']]);
		$cls_definition['update'] = $method;
		$method = $pyjs__bind_method2('onList', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}
			var pk;
			pk = self['list']['getValue'](self['list']['getSelectedIndex']());
			self['callback'](pk, $p['getattr'](self, 'names')['__getitem__'](pk));
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['onList'] = $method;
		$method = $pyjs__bind_method2('setFocus', function(focus) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				focus = arguments[1];
			}
			if (typeof focus == 'undefined') focus=arguments['callee']['__args__'][3][1];

			self['list']['setFocus'](focus);
			self['list']['setSelectedIndex'](0);
			return null;
		}
	, 1, [null,null,['self'],['focus', true]]);
		$cls_definition['setFocus'] = $method;
		$method = $pyjs__bind_method2('onKeyDown', function(sender, keycode, modifiers) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
				keycode = arguments[2];
				modifiers = arguments[3];
			}
			var $and5,$and6,$and7;
			if ($p['bool'](($p['bool']($and5=$p['op_eq'](keycode, 38))?($p['bool']($and6=($p['getattr'](self, 'textbox') !== null))?$p['op_eq'](self['list']['getSelectedIndex'](), 0):$and6):$and5))) {
				self['list']['setValueSelection']($p['list']([]));
				self['textbox']['setFocus'](true);
			}
			return null;
		}
	, 1, [null,null,['self'],['sender'],['keycode'],['modifiers']]);
		$cls_definition['onKeyDown'] = $method;
		$method = $pyjs__bind_method2('onKeyUp', function(sender, keycode, modifiers) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
				keycode = arguments[2];
				modifiers = arguments[3];
			}
			var pk;
			if ($p['bool']($p['op_eq'](keycode, 13))) {
				pk = self['list']['getValue'](self['list']['getSelectedIndex']());
				self['callback'](pk, $p['getattr'](self, 'names')['__getitem__'](pk));
			}
			return null;
		}
	, 1, [null,null,['self'],['sender'],['keycode'],['modifiers']]);
		$cls_definition['onKeyUp'] = $method;
		$method = $pyjs__bind_method2('getSingleElement', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			if ($p['bool']($p['op_eq']($p['len']($p['getattr'](self, 'names')), 1))) {
				return self['names']['items']()['__getitem__'](0);
			}
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['getSingleElement'] = $method;
		var $bases = new Array($m['PopupPanel'],$m['KeyboardHandler']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('SearchPopup', $p['tuple']($bases), $data);
	})();
	$m['SearchBox'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(method, callback) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				method = arguments[1];
				callback = arguments[2];
			}
			if (typeof callback == 'undefined') callback=arguments['callee']['__args__'][4][1];

			$m['TextBox']['__init__'](self);
			self['method'] = method;
			self['addKeyboardListener'](self);
			self['addFocusListener'](self);
			self['pk'] = (typeof ($usub1=1)=='number'?
				-$usub1:
				$p['op_usub']($usub1));
			self['popup'] = null;
			self['callback'] = callback;
			return null;
		}
	, 1, [null,null,['self'],['method'],['callback', null]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('onMethodDone', function(res) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				res = arguments[1];
			}
			var $add17,$add18;
			if ($p['bool'](($p['cmp']($p['len'](res), 0) == 1))) {
				if ($p['bool'](($p['getattr'](self, 'popup') !== null))) {
					self['popup']['update'](res);
				}
				else {
					self['popup'] = $m['SearchPopup'](res, $p['getattr'](self, 'onSearchPopupSelected'), self);
				}
				self['popup']['setPopupPosition'](self['getAbsoluteLeft'](), $p['__op_add']($add17=self['getAbsoluteTop'](),$add18=20));
				self['popup']['show']();
			}
			return null;
		}
	, 1, [null,null,['self'],['res']]);
		$cls_definition['onMethodDone'] = $method;
		$method = $pyjs__bind_method2('onLostFocus', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}
			var el,name,pk;
			if ($p['bool'](($p['getattr'](self, 'popup') !== null))) {
				el = self['popup']['getSingleElement']();
				if ($p['bool']((el !== null))) {
					var $tupleassign3 = $p['__ass_unpack'](el, 2, null);
					pk = $tupleassign3[0];
					name = $tupleassign3[1];
					self['onSearchPopupSelected'](pk, name);
				}
			}
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['onLostFocus'] = $method;
		$method = $pyjs__bind_method2('onKeyUp', function(sender, keycode, modifiers) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
				keycode = arguments[2];
				modifiers = arguments[3];
			}
			var $and8,$and9,search,el,$and10,$and11,pk,name;
			self['removeStyleName']('validation-error');
			if ($p['bool'](($p['bool']($and8=$p['op_eq'](keycode, 40))?($p['getattr'](self, 'popup') !== null):$and8))) {
				self['popup']['setFocus']();
			}
			else if ($p['bool'](($p['bool']($and10=$p['op_eq'](keycode, 13))?($p['getattr'](self, 'popup') !== null):$and10))) {
				el = self['popup']['getSingleElement']();
				if ($p['bool']((el !== null))) {
					var $tupleassign4 = $p['__ass_unpack'](el, 2, null);
					pk = $tupleassign4[0];
					name = $tupleassign4[1];
					self['onSearchPopupSelected'](pk, name);
				}
			}
			else {
				self['pk'] = (typeof ($usub2=1)=='number'?
					-$usub2:
					$p['op_usub']($usub2));
				if ($p['bool'](($p['getattr'](self, 'popup') !== null))) {
					self['popup']['hide']();
				}
				search = self['getText']();
				if ($p['bool'](((($p['cmp']($p['len'](search), 3))|1) == 1))) {
					self['method'](search, $m['JsonHandler']($p['getattr'](self, 'onMethodDone')));
				}
			}
			return null;
		}
	, 1, [null,null,['self'],['sender'],['keycode'],['modifiers']]);
		$cls_definition['onKeyUp'] = $method;
		$method = $pyjs__bind_method2('setValidationError', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			self['addStyleName']('validation-error');
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['setValidationError'] = $method;
		$method = $pyjs__bind_method2('onSearchPopupSelected', function(pk, name) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				pk = arguments[1];
				name = arguments[2];
			}

			self['popup']['hide']();
			self['setText'](name);
			self['pk'] = pk;
			if ($p['bool'](($p['getattr'](self, 'callback') !== null))) {
				self['callback']();
			}
			return null;
		}
	, 1, [null,null,['self'],['pk'],['name']]);
		$cls_definition['onSearchPopupSelected'] = $method;
		var $bases = new Array($m['TextBox'],$m['KeyboardHandler'],$m['FocusListener']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('SearchBox', $p['tuple']($bases), $data);
	})();
	$m['InputMapper'] = (function(){
		var $cls_definition = new Object();
		var $method;
		$cls_definition['__module__'] = 'util';
		$method = $pyjs__bind_method2('__init__', function(pk, desc, load_method, save_method, save_button, save_callback, load_callback, close_button, close_callback) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				pk = arguments[1];
				desc = arguments[2];
				load_method = arguments[3];
				save_method = arguments[4];
				save_button = arguments[5];
				save_callback = arguments[6];
				load_callback = arguments[7];
				close_button = arguments[8];
				close_callback = arguments[9];
			}
			if (typeof save_callback == 'undefined') save_callback=arguments['callee']['__args__'][8][1];
			if (typeof load_callback == 'undefined') load_callback=arguments['callee']['__args__'][9][1];
			if (typeof close_button == 'undefined') close_button=arguments['callee']['__args__'][10][1];
			if (typeof close_callback == 'undefined') close_callback=arguments['callee']['__args__'][11][1];
			var $iter16_array,el,$iter16_type,$iter16_nextval,$iter16_idx,$iter16_iter;
			self['pk'] = pk;
			self['desc'] = desc;
			self['load_method'] = load_method;
			self['save_method'] = save_method;
			self['desc'] = $p['dict']([]);
			$iter16_iter = desc;
			$iter16_nextval=$p['__iter_prepare']($iter16_iter,false);
			while (typeof($p['__wrapped_next']($iter16_nextval)['$nextval']) != 'undefined') {
				el = $iter16_nextval['$nextval'];
				$p['getattr'](self, 'desc')['__setitem__'](el['__getitem__']('name'), el);
				if ($p['bool']($p['list'](['free', 'single', 'multi'])['__contains__'](el['__getitem__']('type')))) {
					el['__getitem__']('input')['addChangeListener']($p['getattr'](self, 'onChange'));
					if ($p['bool']($p['op_eq'](el['__getitem__']('type'), 'free'))) {
						el['__getitem__']('input')['addKeyboardListener'](self);
					}
				}
			}
			self['load']();
			self['save_button'] = save_button;
			if ($p['bool']((save_button !== null))) {
				save_button['addClickListener']($p['getattr'](self, 'onSaveButton'));
			}
			self['save_callback'] = save_callback;
			self['load_callback'] = load_callback;
			self['modified'] = false;
			self['close_button'] = close_button;
			self['close_callback'] = close_callback;
			if ($p['bool'](($p['getattr'](self, 'close_button') !== null))) {
				self['close_button']['addClickListener']($p['getattr'](self, 'onCloseButton'));
			}
			return null;
		}
	, 1, [null,null,['self'],['pk'],['desc'],['load_method'],['save_method'],['save_button'],['save_callback', null],['load_callback', null],['close_button', null],['close_callback', null]]);
		$cls_definition['__init__'] = $method;
		$method = $pyjs__bind_method2('setModified', function(modified) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				modified = arguments[1];
			}
			if (typeof modified == 'undefined') modified=arguments['callee']['__args__'][3][1];
			var $and12,$and13,$and14,$and15;
			if ($p['bool'](($p['bool']($and12=modified)?!$p['bool']($p['getattr'](self, 'modified')):$and12))) {
				self['modified'] = true;
				if ($p['bool'](($p['getattr'](self, 'close_button') !== null))) {
					self['close_button']['setText']('Annulla');
				}
			}
			else if ($p['bool'](($p['bool']($and14=!$p['bool'](modified))?$p['getattr'](self, 'modified'):$and14))) {
				self['modified'] = false;
				if ($p['bool'](($p['getattr'](self, 'close_button') !== null))) {
					self['close_button']['setText']('Chiudi');
				}
			}
			return null;
		}
	, 1, [null,null,['self'],['modified', true]]);
		$cls_definition['setModified'] = $method;
		$method = $pyjs__bind_method2('onChange', function(sender) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
			}

			sender['removeStyleName']('validation-error');
			self['setModified']();
			return null;
		}
	, 1, [null,null,['self'],['sender']]);
		$cls_definition['onChange'] = $method;
		$method = $pyjs__bind_method2('onKeyUp', function(sender, keycode, modifiers) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				sender = arguments[1];
				keycode = arguments[2];
				modifiers = arguments[3];
			}

			sender['removeStyleName']('validation-error');
			self['setModified']();
			return null;
		}
	, 1, [null,null,['self'],['sender'],['keycode'],['modifiers']]);
		$cls_definition['onKeyUp'] = $method;
		$method = $pyjs__bind_method2('onSaveDone', function(res) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				res = arguments[1];
			}
			var $iter17_nextval,$iter17_iter,d,f,$iter17_array,$iter17_idx,$iter17_type;
			if ($p['bool']($p['op_eq'](res['__getitem__']('status'), 'OK'))) {
				self['pk'] = res['__getitem__']('pk');
			}
			else {
				$pyjs_kwargs_call(null, $m['DissolvingPopup'], null, null, [{'error':true}, res['__getitem__']('msg')]);
				$iter17_iter = res['__getitem__']('fields');
				$iter17_nextval=$p['__iter_prepare']($iter17_iter,false);
				while (typeof($p['__wrapped_next']($iter17_nextval)['$nextval']) != 'undefined') {
					f = $iter17_nextval['$nextval'];
					d = $p['getattr'](self, 'desc')['__getitem__'](f);
					if ($p['bool']($p['list'](['free', 'multi', 'single'])['__contains__'](d['__getitem__']('type')))) {
						d['__getitem__']('input')['addStyleName']('validation-error');
					}
					else if ($p['bool']($p['list'](['address', 'foreign'])['__contains__'](d['__getitem__']('type')))) {
						d['__getitem__']('input')['setValidationError']();
					}
				}
			}
			if ($p['bool'](($p['getattr'](self, 'save_button') !== null))) {
				self['save_button']['setEnabled'](true);
			}
			self['setModified'](false);
			if ($p['bool'](($p['getattr'](self, 'save_callback') !== null))) {
				self['save_callback'](res);
			}
			return null;
		}
	, 1, [null,null,['self'],['res']]);
		$cls_definition['onSaveDone'] = $method;
		$method = $pyjs__bind_method2('save', function(callback) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				callback = arguments[1];
			}
			var $iter18_type,$iter18_iter,name,$iter18_array,d,$iter18_idx,t,input,$iter18_nextval,out;
			out = $p['dict']([]);
			$iter18_iter = $p['getattr'](self, 'desc');
			$iter18_nextval=$p['__iter_prepare']($iter18_iter,false);
			while (typeof($p['__wrapped_next']($iter18_nextval)['$nextval']) != 'undefined') {
				name = $iter18_nextval['$nextval'];
				d = $p['getattr'](self, 'desc')['__getitem__'](name);
				t = d['__getitem__']('type');
				input = d['__getitem__']('input');
				if ($p['bool']($p['op_eq'](t, 'free'))) {
					out['__setitem__'](name, input['getText']());
				}
				else if ($p['bool']($p['op_eq'](t, 'single'))) {
					out['__setitem__'](name, input['getValue'](input['getSelectedIndex']()));
				}
				else if ($p['bool']($p['op_eq'](t, 'multi'))) {
					out['__setitem__'](name, '');
				}
				else if ($p['bool']($p['op_eq'](t, 'foreign'))) {
					out['__setitem__'](name, ($p['bool'](($p['cmp']($p['getattr'](input, 'pk'), (typeof ($usub3=1)=='number'?
						-$usub3:
						$p['op_usub']($usub3))) == 1))? ($p['getattr'](input, 'pk')) : (null)));
				}
				else if ($p['bool']($p['op_eq'](t, 'custom'))) {
					out['__setitem__'](name, input());
				}
				else if ($p['bool']($p['op_eq'](t, 'address'))) {
					out['__setitem__'](name, input['getAddress']());
				}
			}
			self['callback'] = callback;
			self['save_method']($p['getattr'](self, 'pk'), out, $m['JsonHandler']($p['getattr'](self, 'onSaveDone')));
			return null;
		}
	, 1, [null,null,['self'],['callback']]);
		$cls_definition['save'] = $method;
		$method = $pyjs__bind_method2('onSaveButton', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			self['save_button']['setEnabled'](false);
			self['save']();
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['onSaveButton'] = $method;
		$method = $pyjs__bind_method2('onCloseButton', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			self['confirmClose']($p['getattr'](self, 'close_callback'));
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['onCloseButton'] = $method;
		$method = $pyjs__bind_method2('confirmClose', function(callback_yes, callback_no) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				callback_yes = arguments[1];
				callback_no = arguments[2];
			}
			if (typeof callback_no == 'undefined') callback_no=arguments['callee']['__args__'][4][1];

			if ($p['bool'](!$p['bool']($p['getattr'](self, 'modified')))) {
				if ($p['bool']((callback_yes !== null))) {
					callback_yes();
				}
			}
			else {
				$m['QuestionDialogBox']('Conferma', 'Ci sono modifiche non salvate. Confermi la chiusura?', $p['list']([$p['tuple'](['S&igrave;', callback_yes, null]), $p['tuple'](['No', callback_no, null])]))['show']();
			}
			return null;
		}
	, 1, [null,null,['self'],['callback_yes'],['callback_no', null]]);
		$cls_definition['confirmClose'] = $method;
		$method = $pyjs__bind_method2('onLoadDone', function(res) {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
				res = arguments[1];
			}
			var el,$iter20_nextval,iname,ipk,lng,$iter20_array,$iter19_iter,$iter19_nextval,$iter19_type,text,pk,type,$iter20_iter,$iter19_array,$iter20_type,input,lat,$add19,d,$iter19_idx,name,i,item,$iter20_idx,$add20;
			$iter19_iter = res;
			$iter19_nextval=$p['__iter_prepare']($iter19_iter,false);
			while (typeof($p['__wrapped_next']($iter19_nextval)['$nextval']) != 'undefined') {
				name = $iter19_nextval['$nextval'];
				el = res['__getitem__'](name);
				d = $p['getattr'](self, 'desc')['__getitem__'](name);
				input = d['__getitem__']('input');
				type = d['__getitem__']('type');
				if ($p['bool']($p['op_eq'](type, 'free'))) {
					input['setText'](el);
				}
				else if ($p['bool']($p['op_eq'](type, 'single'))) {
					input['clear']();
					pk = el['__getitem__'](0);
					i = 0;
					$iter20_iter = el['__getitem__'](1);
					$iter20_nextval=$p['__iter_prepare']($iter20_iter,false);
					while (typeof($p['__wrapped_next']($iter20_nextval)['$nextval']) != 'undefined') {
						item = $iter20_nextval['$nextval'];
						var $tupleassign5 = $p['__ass_unpack'](item, 2, null);
						ipk = $tupleassign5[0];
						iname = $tupleassign5[1];
						input['addItem'](iname, ipk);
						if ($p['bool']($p['op_eq'](ipk, pk))) {
							input['setSelectedIndex'](i);
						}
						i = $p['__op_add']($add19=i,$add20=1);
					}
				}
				else if ($p['bool']($p['op_eq'](type, 'multi'))) {
				}
				else if ($p['bool']($p['op_eq'](type, 'foreign'))) {
					var $tupleassign6 = $p['__ass_unpack'](el, 2, null);
					pk = $tupleassign6[0];
					text = $tupleassign6[1];
					input['setText'](text);
					input['pk'] = pk;
				}
				else if ($p['bool']($p['op_eq'](type, 'custom'))) {
				}
				else if ($p['bool']($p['op_eq'](type, 'address'))) {
					var $tupleassign7 = $p['__ass_unpack'](el, 3, null);
					text = $tupleassign7[0];
					lng = $tupleassign7[1];
					lat = $tupleassign7[2];
					input['setAddress'](text, lng, lat);
				}
			}
			if ($p['bool'](($p['getattr'](self, 'load_callback') !== null))) {
				self['load_callback'](res);
			}
			return null;
		}
	, 1, [null,null,['self'],['res']]);
		$cls_definition['onLoadDone'] = $method;
		$method = $pyjs__bind_method2('load', function() {
			if (this['__is_instance__'] === true) {
				var self = this;
			} else {
				var self = arguments[0];
			}

			self['load_method']($p['getattr'](self, 'pk'), $m['JsonHandler']($p['getattr'](self, 'onLoadDone')));
			return null;
		}
	, 1, [null,null,['self']]);
		$cls_definition['load'] = $method;
		var $bases = new Array($m['KeyboardHandler']);
		var $data = $p['dict']();
		for (var $item in $cls_definition) { $data['__setitem__']($item, $cls_definition[$item]); }
		return $p['_create_class']('InputMapper', $p['tuple']($bases), $data);
	})();
	return this;
}; /* end util */


/* end module: util */


/*
PYJS_DEPS: ['prnt.prnt', 'prnt', 'pyjamas.ui.Calendar.Calendar', 'pyjamas', 'pyjamas.ui', 'pyjamas.ui.Calendar', 'pyjamas.ui.Calendar.DateField', 'pyjamas.ui.RootPanel.RootPanel', 'pyjamas.ui.RootPanel', 'pyjamas.ui.VerticalPanel.VerticalPanel', 'pyjamas.ui.VerticalPanel', 'pyjamas.ui.HorizontalPanel.HorizontalPanel', 'pyjamas.ui.HorizontalPanel', 'pyjamas.ui.SimplePanel.SimplePanel', 'pyjamas.ui.SimplePanel', 'pyjamas.ui.DisclosurePanel.DisclosurePanel', 'pyjamas.ui.DisclosurePanel', 'pyjamas.ui.DialogBox.DialogBox', 'pyjamas.ui.DialogBox', 'pyjamas.ui.TabPanel.TabPanel', 'pyjamas.ui.TabPanel', 'pyjamas.ui.Grid.Grid', 'pyjamas.ui.Grid', 'pyjamas.ui.Frame.Frame', 'pyjamas.ui.Frame', 'pyjamas.ui.TextBox.TextBox', 'pyjamas.ui.TextBox', 'pyjamas.ui.TextArea.TextArea', 'pyjamas.ui.TextArea', 'pyjamas.ui.HTML.HTML', 'pyjamas.ui.HTML', 'pyjamas.ui.FlowPanel.FlowPanel', 'pyjamas.ui.FlowPanel', 'pyjamas.ui.FlexTable.FlexTable', 'pyjamas.ui.FlexTable', 'pyjamas.ui.Anchor.Anchor', 'pyjamas.ui.Anchor', 'pyjamas.ui.FlexCellFormatter.FlexCellFormatter', 'pyjamas.ui.FlexCellFormatter', 'pyjamas.ui.Label.Label', 'pyjamas.ui.Label', 'pyjamas.ui.CheckBox.CheckBox', 'pyjamas.ui.CheckBox', 'pyjamas.ui.ListBox.ListBox', 'pyjamas.ui.ListBox', 'pyjamas.ui.Button.Button', 'pyjamas.ui.Button', 'pyjamas.ui.ToggleButton.ToggleButton', 'pyjamas.ui.ToggleButton', 'pyjamas.ui.PopupPanel.PopupPanel', 'pyjamas.ui.PopupPanel', 'pyjamas.ui.KeyboardListener.KeyboardHandler', 'pyjamas.ui.KeyboardListener', 'pyjamas.ui.FocusListener.FocusHandler', 'pyjamas.ui.FocusListener', 'pyjamas.ui.Tree.Tree', 'pyjamas.ui.Tree', 'pyjamas.ui.Tree.TreeItem', 'pyjamas.ui.Image.Image', 'pyjamas.ui.Image', 'pyjamas.ui.HasAlignment', 'pyjamas.ui.HorizontalSplitPanel', 'pyjamas.ui.MenuBar.MenuBar', 'pyjamas.ui.MenuBar', 'pyjamas.ui.MenuItem.MenuItem', 'pyjamas.ui.MenuItem', 'pyjamas.ui.Widget.Widget', 'pyjamas.ui.Widget', 'pyjamas.ui.Hyperlink.Hyperlink', 'pyjamas.ui.Hyperlink', 'pyjamas.Window', 'pyjamas.Timer.Timer', 'pyjamas.Timer', 'datetime.date', 'datetime', 'datetime.time', 'datetime.datetime', 'datetime.timedelta', 'DissolvingPopup.DissolvingPopup', 'DissolvingPopup', 'pyjamas.ui.HTMLPanel.HTMLPanel', 'pyjamas.ui.HTMLPanel']
*/
