/* * jQuery Mobile Framework: "controlgroup" plugin - corner-rounding for groups of buttons, checks, radios, etc * Copyright (c) jQuery Project * Dual licensed under the MIT or GPL Version 2 licenses. * http://jquery.org/license */ (function( $, undefined ) { //auto self-init widgets $( document ).bind( "pagecreate create", function( e ){ $( ":jqmData(role='controlgroup')", e.target ).controlgroup({ excludeInvisible: false }); }); $.fn.controlgroup = function( options ) { return this.each(function() { var $el = $( this ), o = $.extend({ direction: $el.jqmData( "type" ) || "vertical", shadow: false, excludeInvisible: true }, options ), groupheading = $el.find( ">legend" ), flCorners = o.direction == "horizontal" ? [ "ui-corner-left", "ui-corner-right" ] : [ "ui-corner-top", "ui-corner-bottom" ], type = $el.find( "input:eq(0)" ).attr( "type" ); // Replace legend with more stylable replacement div if ( groupheading.length ) { $el.wrapInner( "
" ); $( "