summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2018-01-25 18:52:21 +0300
committerAndrew Dolgov <[email protected]>2018-01-25 18:52:21 +0300
commitf0deb0736294d72c5edc38d2569c59eb2cac67ab (patch)
tree9e384468528bb60d83131dc51dc9903e991de297 /js
parentf11c22169f9468ddb2dcdfa51da7327d91d35396 (diff)
fullscreen (not working)
Diffstat (limited to 'js')
-rw-r--r--js/read.js16
1 files changed, 16 insertions, 0 deletions
diff --git a/js/read.js b/js/read.js
index f56df46..e6ad650 100644
--- a/js/read.js
+++ b/js/read.js
@@ -1,5 +1,19 @@
var _store_position = 0;
+function request_fullscreen() {
+ localforage.getItem("epube.enable-fullscreen").then(function(enable) {
+
+ if (enable) {
+ var elem = document.documentElement;
+ var func = elem.webkitRequestFullscreen;
+
+ if (typeof func != "undefined") {
+ func.call(elem);
+ }
+ }
+ });
+}
+
function show_ui(show) {
if (show)
$(".header,.footer").fadeIn();
@@ -18,11 +32,13 @@ function next_page() {
_store_position = 1;
window.book.nextPage();
+
show_ui(false);
}
function prev_page() {
window.book.prevPage();
+
show_ui(false);
}