2 * Copyright (c) 2012, Intel Corporation.
4 * This program is licensed under the terms and conditions of the
5 * Apache License, version 2.0. The full text of the Apache License is at
6 * http://www.apache.org/licenses/LICENSE-2.0
10 (function($, undefined) {
13 var ChCheckboxInput = function(element, options) {
14 $.fn.ch_widget.Constructor(element, options);
15 this.$element = $(element);
16 this.options = $.extend(
18 $.fn.ch_widget.defaults,
20 disableWhenDriving: true
24 ChCheckboxInput.prototype = $.extend(
26 $.fn.ch_widget.Constructor.prototype,
28 constructor: ChCheckboxInput
32 $.fn.ch_checkbox_input = function(option) {
33 return this.each(function() {
35 data = $this.data('ch_checkbox_input'),
36 options = typeof option == 'object' && option;
39 $this.data('ch_checkbox_input', (data = new ChCheckboxInput(this, options)));
45 $.fn.ch_checkbox_input.Constructor = ChCheckboxInput;
47 /* CHCHECKBOXINPUT DATA-API
48 * ================= */
50 $('input[type=checkbox]').ch_checkbox_input();