From 600cc9c3e95897905a8355bbf512874231af3544 Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Mon, 3 Feb 2014 13:30:50 +0000 Subject: [PATCH] OSX does not trigger keydown on paste, also listen to paste event to check for changes, fixes #2170 --- source/Ox.UI/js/Form/Input.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/source/Ox.UI/js/Form/Input.js b/source/Ox.UI/js/Form/Input.js index 922fc116..26a674a9 100644 --- a/source/Ox.UI/js/Form/Input.js +++ b/source/Ox.UI/js/Form/Input.js @@ -294,6 +294,12 @@ Ox.Input = function(options, self) { }) .appendTo(that); + if (self.bindKeyboard) { + self.$input.on({ + paste: keydown + }); + } + if (self.options.type == 'textarea') { Ox.Log('Form', 'TEXTAREA', self.options.width, self.options.height, '...', that.css('width'), that.css('height'), '...', self.$input.css('width'), self.$input.css('height'), '...', self.$input.css('border')) } @@ -826,7 +832,7 @@ Ox.Input = function(options, self) { change: {value: self.options.value} }); } - }, 0); + }); } if ( (event.keyCode == 38 || event.keyCode == 40) // up/down