summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--css/images/ajax-loader.gifbin1928 -> 6242 bytes
-rw-r--r--css/index.css7
-rw-r--r--index.html4
-rw-r--r--js/index.js11
4 files changed, 5 insertions, 17 deletions
diff --git a/css/images/ajax-loader.gif b/css/images/ajax-loader.gif
index 15e24db..57f5624 100644
--- a/css/images/ajax-loader.gif
+++ b/css/images/ajax-loader.gif
Binary files differ
diff --git a/css/index.css b/css/index.css
index cca4c21..17ff626 100644
--- a/css/index.css
+++ b/css/index.css
@@ -53,10 +53,3 @@ body {
.pdfpage {
overflow: auto;
}
-
-#loadercontainer {
- width: 24px;
- display: block;
- margin-left: auto;
- margin-right: auto;
-}
diff --git a/index.html b/index.html
index eeba963..ca30d8d 100644
--- a/index.html
+++ b/index.html
@@ -36,10 +36,6 @@
</div>
<div id="login" class="ui-content">
- <div id="loadercontainer">
- <img id="loader" src="css/images/ajax-loader.gif">
- </div>
-
<div data-role="popup" id="loginpopup" data-theme="a">
<form style="padding:10px 20px;" id="loginform" action="javascript:login();">
<h3>Bitte einloggen</h3>
diff --git a/js/index.js b/js/index.js
index a520df9..99d78ea 100644
--- a/js/index.js
+++ b/js/index.js
@@ -29,13 +29,9 @@ $(document).bind('pageinit', function(){
}, 2000);
});
-/* der Loader wird nur im Login-Tab angezeigt, wenn das Popup zu ist */
-$('#loginpopup').on('popupafterclose', function(){
- $('#loader').show('fast');
-});
-
+/* der Loader wird nur angezeigt, wenn das Popup zu ist */
$('#loginpopup').on('popupafteropen', function(){
- $('#loader').hide('slow');
+ $.mobile.loading('hide');
});
/* füllt die Loginform mit gespeicherten Werten */
@@ -94,6 +90,7 @@ function render_pdf(url, divstr){
var pageNumber = 1;
renderPage($viewer, pdf, pageNumber++, function pageRenderingComplete(){
if(pageNumber > pdf.numPages){
+ $.mobile.loading('hide'); // nach dem Rendern des ersten PDFs Loader verstecken
return;
}
renderPage($viewer, pdf, pageNumber++, pageRenderingComplete);
@@ -326,6 +323,7 @@ function getuserdata(){
/* loggt ein oder zeigt Loginform */
function login(){
+ $.mobile.loading('show', {theme: 'a'});
userdata = getuserdata();
if(userdata){
@@ -377,6 +375,7 @@ function getactual(entries){
/* lädt Vertretungspläne aus dem Speicher [1) SD-Karte oder 2) dem internen Speicher] */
function load(){
+ $.mobile.loading('show', {theme: 'a'});
window.requestFileSystem(
LocalFileSystem.PERSISTENT, 0,
function(fileSystem){