Checkboxradio: change fires twice when hitting space on the widget #7378

gabrielschulhof opened this Issue May 7, 2014 · 0 comments


None yet

1 participant


Steps to reproduce:

  1. Visit
  2. Press TAB until the checkbox is highlighted
  3. Hit space

At this point you will find that change fires twice, recording the value of the input's checked property in the "console".

For comparison, click on the checkbox instead. The problem is that the space bar triggers a vclick - yes, a vclick, which causes the checkboxradio code to trigger a change event. However, the input also natively triggers change in response to the spacebar. That makes two change events for each space bar press.

@gabrielschulhof gabrielschulhof added this to the 1.4.3 milestone May 7, 2014
@gabrielschulhof gabrielschulhof self-assigned this May 7, 2014
@gabrielschulhof gabrielschulhof added a commit that referenced this issue May 27, 2014
@gabrielschulhof gabrielschulhof Checkboxradio: Do not update twice upon input vclick
(cherry picked from commit 805ff49)

Fixes gh-7378
@agcolom agcolom added a commit to agcolom/jquery-mobile that referenced this issue Nov 26, 2014
@gabrielschulhof @agcolom gabrielschulhof + agcolom Checkboxradio: Do not update twice upon input vclick
Fixes gh-7378
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment