mirror of
https://github.com/Hopiu/jquery-mobile.git
synced 2026-05-18 03:21:07 +00:00
Removed correct side of rounded corners on buttons in listviews that either precede or follow dividers.
Note that this will also make sure there's no bottom corners on a button that predes a divider that comes last, if that ever happens. Fixes #139
This commit is contained in:
parent
cc6389b707
commit
af9508481c
1 changed files with 12 additions and 0 deletions
|
|
@ -168,6 +168,18 @@ $.widget( "mobile.listview", $.mobile.widget, {
|
|||
.addClass( "ui-li-thumb" );
|
||||
|
||||
if ( o.inset ) {
|
||||
|
||||
//remove corners before or after dividers
|
||||
var sides = ['top','bottom'];
|
||||
$.each( sides, function( i ){
|
||||
var side = sides[ i ];
|
||||
$list.find( ".ui-corner-" + side ).each(function(){
|
||||
if( $(this).parents('li')[ i == 0 ? 'prev' : 'next' ]( ".ui-li-divider" ).length ){
|
||||
$(this).removeClass( "ui-corner-" + side );
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
this.element
|
||||
.find( "img" )
|
||||
.filter( "li:first-child img" )
|
||||
|
|
|
|||
Loading…
Reference in a new issue