1
0
Fork 0
forked from 0x2620/oxjs

.bind -> .on, .unbind -> .off

This commit is contained in:
rolux 2012-05-28 16:06:22 +02:00
commit 461a237880
22 changed files with 54 additions and 54 deletions

View file

@ -80,7 +80,7 @@ Ox.ArrayInput = function(options, self) {
type: 'image'
})
.css({float: 'left', marginLeft: '8px'})
.bind({
.on({
click: function() {
var index = $(this).parent().data('index');
if (self.$input[index].value() !== '') {
@ -104,7 +104,7 @@ Ox.ArrayInput = function(options, self) {
type: 'image'
})
.css({float: 'left', marginLeft: '8px'})
.bind({
.on({
click: function() {
var index = $(this).parent().data('index');
addInput(index + 1, '', true);

View file

@ -35,7 +35,7 @@ Ox.Editable = function(options, self) {
})
.options(options || {})
.addClass('OxEditableElement' + (self.options.editable ? ' OxEditable' : ''))
.bind({
.on({
click: function() {
return false;
}

View file

@ -92,7 +92,7 @@ Ox.FileButton = function(options, self) {
marginLeft: -self.options.width + 'px',
opacity: 0
})
.bind({
.on({
change: selectFiles
})
.appendTo(that);

View file

@ -277,7 +277,7 @@ Ox.FileInput = function(options, self) {
margin: '-1px -7px 0 -16px',
opacity: 0
})
.bind({
.on({
change: addFiles
})
.appendTo(self.$bar);

View file

@ -596,7 +596,7 @@ Ox.Input = function(options, self) {
self.options.autovalidate && autovalidate(true);
self.options.placeholder && setPlaceholder();
self.options.validate && validate();
self.bindKeyboard && Ox.UI.$document.unbind('keydown', keydown);
self.bindKeyboard && Ox.UI.$document.off('keydown', keydown);
if (!self.cancelled && !self.submitted) {
that.triggerEvent('blur', {
value: self.options.value

View file

@ -77,7 +77,7 @@ Ox.ObjectArrayInput = function(options, self) {
width: self.buttonWidth
})
.css({float: 'left', margin: '8px 4px 0 0'})
.bind({
.on({
click: function() {
var index = $(this).parent().data('index');
if (self.$input.length > 1) {
@ -97,7 +97,7 @@ Ox.ObjectArrayInput = function(options, self) {
width: self.buttonWidth
})
.css({float: 'left', margin: '8px 0 0 4px'})
.bind({
.on({
click: function() {
var index = $(this).parent().data('index');
addInput(index + 1, getDefaultValue());

View file

@ -92,7 +92,7 @@ Ox.PlacePicker = function(options, self) {
}, self)
.bindEvent('show', showPicker);
that.$label.bind('click', clickLabel);
that.$label.on('click', clickLabel);
self.map = false;