Fix for issue 841 - Persistent footers persist even when going to other pages that don't have footers or don't have footers with the same data-id.

This was a regression I caused with my previous checkin. The fix is to simply null out stickyFooter in the pagebeforeshow callback.
This commit is contained in:
Kin Blas 2011-01-20 12:51:28 -08:00
parent 161f5e6ae3
commit e4042266fb

View file

@ -69,9 +69,10 @@ $.fixedToolbars = (function(){
//before page is shown, check for duplicate footer
$('.ui-page').live('pagebeforeshow', function(event, ui){
var page = $(event.target);
var footer = page.find('[data-role="footer"]:not(.ui-sticky-footer)');
var id = footer.data('id');
var page = $(event.target),
footer = page.find('[data-role="footer"]:not(.ui-sticky-footer)'),
id = footer.data('id');
stickyFooter = null;
if (id)
{
stickyFooter = $('.ui-footer[data-id="' + id + '"].ui-sticky-footer');