Enable/disable from buttons on all input events (not just key events)

Fixes #1836
This commit is contained in:
Riyad Preukschas 2012-10-27 17:00:51 +02:00
parent 13e72f5a6f
commit 2f5e44a02d

View file

@ -14,7 +14,7 @@ window.disableButtonIfEmptyField = (field_selector, button_selector) ->
closest_submit.disable() if field.val() is ""
field.on "keyup", ->
field.on "input", ->
if $(@).val() is ""
closest_submit.disable()
else