fix back function on android

This commit is contained in:
Stefan Breunig 2013-03-08 11:08:47 +01:00
parent 1e2935c018
commit eed1b9cef2

View File

@ -19,13 +19,13 @@ window.setupBackButton = function() {
window.goBack = function() { window.goBack = function() {
while(window.setupBackButton._actions.length > 0) { while(window.setupBackButton._actions.length > 0) {
var a = window.setupBackButton._actions.pop(); var a = $(window.setupBackButton._actions.pop());
// skip no-op back actions. This may occur then the expand/shrink // skip no-op back actions. This may occur then the expand/shrink
// button is used. // button is used.
if($(a).hasClass('active')) continue; if(a.hasClass('active')) continue;
window.setupBackButton._ignoreNextClick = true; window.setupBackButton._ignoreNextClick = true;
a.click(); a.click();
console.log('Going back to ' + $(a).text()); console.log('Going back to ' + a.text());
break; break;
} }
} }