if (this.landingpage !== undefined) {
this.landingpage.hide();
}
- this.menu.closeView(function () {
+ this.menu._closeView(function () {
if (page != $this.currentPage) {
$this.pageTransition(page);
$this.stats.track(0, page);
// This was added for #viewOverlay in the CSS
// More details: https://stackoverflow.com/a/16006333
$(document).on('click', ".mview .back, #viewOverlay", function () {
- var currentHash = window.location.hash;
- window.location.hash = '/page/' + $this.fluidbook.currentPage;
- if (window.location.hash == currentHash) {
- $this.closeView(function () {
- }, true);
- }
-
+ $this.closeView(function(){},true);
return false;
});
callback();
}
},
+
closeView: function (callback, all, animate) {
+ if (callback === undefined) {
+ callback = function () {
+ };
+ }
+
+ var currentHash = window.location.hash;
+ window.location.hash = '/page/' + $this.fluidbook.currentPage;
+ if (window.location.hash == currentHash) {
+ this._closeView(callback, all, animate);
+ }
+ },
+ _closeView: function (callback, all, animate) {
this.hideOverlay();
var $this = this;
if (all == undefined) {