]> _ Git - fluidbook-html5.git/commitdiff
#1328
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Fri, 7 Apr 2017 18:09:50 +0000 (20:09 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Fri, 7 Apr 2017 18:09:50 +0000 (20:09 +0200)
js/libs/fluidbook/fluidbook.nav.js

index 018f0d37cb76ae7ff08be4d89a154b77f7c8c653..80adbb7a66dd67d8a2d134f3c6964336031a5306 100644 (file)
@@ -85,7 +85,7 @@ FluidbookNav.prototype = {
             if (icon == 'home' && !skipHome) {
 
                 var homeURL = this.fluidbook.datas.home;
-                if (this.fluidbook.datas.home == '%apphome%') {
+                if (this.fluidbook.datas.home == '%apphome%' || forceHome && DATAS.phonegap) {
                     homeURL = decodeURIComponent(window.localStorage.getItem('apphome'));
                 }
                 if ($_GET['home'] != null) {
@@ -98,6 +98,15 @@ FluidbookNav.prototype = {
                 } catch (err) {
 
                 }
+
+                $('#home').on('click', function () {
+                    var $this = this;
+                    fluidbook.displayLoader();
+                    setTimeout(function () {
+                        window.location = $($this).attr('href');
+                    }, 500);
+                    return false;
+                })
             } else if (icon == 'index') {
                 this.addLink('nav-index', '#/index', 'index', 'overview');
             } else if (icon == 'chapters') {