mirror of
https://github.com/apache/cordova-android.git
synced 2025-01-31 17:32:51 +08:00
Backbutton should go back in appview history before going back in our history stack.
JQMobile uses htmlPage#div to navigate "multipage" apps. When the webview navigates between tags in the same page, it is added to the webview history.
This commit is contained in:
parent
e9fcb296bb
commit
fd93404c7c
@ -1450,7 +1450,11 @@ public class DroidGap extends PhonegapActivity {
|
||||
else {
|
||||
|
||||
// Go to previous page in webview if it is possible to go back
|
||||
if (this.urls.size() > 1) {
|
||||
if (this.appView.canGoBack()) {
|
||||
this.appView.goBack(); // This is needed to support curPage#diffLink, since they are added to appView's history, but not our history url array (JQMobile behavior)
|
||||
return true;
|
||||
}
|
||||
else if (this.urls.size() > 1) {
|
||||
this.backHistory();
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user