From ff2ef4076b2531150939b690b6a16e9fdcba2113 Mon Sep 17 00:00:00 2001 From: Tobias Bosch Date: Thu, 23 Jun 2011 13:31:05 +0200 Subject: [PATCH] fix issue 1851 as suggested --- js/jquery.mobile.forms.checkboxradio.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/js/jquery.mobile.forms.checkboxradio.js b/js/jquery.mobile.forms.checkboxradio.js index 3df31422..7be6b359 100644 --- a/js/jquery.mobile.forms.checkboxradio.js +++ b/js/jquery.mobile.forms.checkboxradio.js @@ -110,7 +110,10 @@ $.widget( "mobile.checkboxradio", $.mobile.widget, { //returns either a set of radios with the same name attribute, or a single checkbox _getInputSet: function(){ - return this.element.closest( "form,fieldset,:jqmData(role='page')" ) + if(this.inputtype == "checkbox") { + return this.element; + } + return this.element.closest( "form,fieldset,:jqmData(role='page')" ) .find( "input[name='"+ this.element.attr( "name" ) +"'][type='"+ this.inputtype +"']" ); },