mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 04:44:11 +02:00
Make the back button work again, uses the browser history directly now.
This commit is contained in:
parent
e5ac3eeea7
commit
608becef7d
1 changed files with 2 additions and 9 deletions
|
@ -25,9 +25,7 @@
|
|||
var canWriteAssets = false;
|
||||
var xmlHttpRequest = null;
|
||||
var isPreparing = false; // Explicitly track download request status.
|
||||
|
||||
var lastPage = "https://metaverse.highfidelity.com/marketplace?";
|
||||
|
||||
|
||||
function injectCommonCode(isDirectoryPage) {
|
||||
|
||||
// Supporting styles from marketplaces.css.
|
||||
|
@ -67,7 +65,7 @@
|
|||
|
||||
// Footer actions.
|
||||
$("#back-button").on("click", function () {
|
||||
window.location = lastPage;
|
||||
window.history.back();
|
||||
});
|
||||
$("#all-markets").on("click", function () {
|
||||
EventBridge.emitWebEvent(GOTO_DIRECTORY);
|
||||
|
@ -344,12 +342,7 @@
|
|||
}
|
||||
}
|
||||
|
||||
function locationChanged() {
|
||||
lastPage = location.href;
|
||||
}
|
||||
|
||||
// Load / unload.
|
||||
window.addEventListener("load", onLoad); // More robust to Web site issues than using $(document).ready().
|
||||
window.addEventListener("hashchange", locationChanged);
|
||||
|
||||
}());
|
||||
|
|
Loading…
Reference in a new issue