Skip to content
Snippets Groups Projects
Commit 29a9c97f authored by Julian Pustkuchen's avatar Julian Pustkuchen
Browse files

Fixed AJAX functionality.

parent fb00a643
Branches
Tags
No related merge requests found
......@@ -23,7 +23,7 @@
$(element).click(function(eventObject) {
// Nicht bei Öffnen in neuem Tab (Strg+Klick)
if (!eventObject.ctrlKey) {
Loadinganimation.show();
Drupal.behaviors.jquery_loadinganimation.Loadinganimation.show();
}
});
}
......@@ -38,7 +38,7 @@
if (typeof $(this).data("events") == 'undefined'
|| $(this).data("events").length == 0
) {
Loadinganimation.show();
Drupal.behaviors.jquery_loadinganimation.Loadinganimation.show();
} else {
var show=true;
jQuery.each($(this).data("events"), function(index, element){
......@@ -47,7 +47,7 @@
}
});
if(show){
Loadinganimation.show();
Drupal.behaviors.jquery_loadinganimation.Loadinganimation.show();
}
}
});
......@@ -55,7 +55,7 @@
// Bei Klick auf die Animation ausblenden
$("div#loadinganimation").click(function() {
Loadinganimation.hide();
Drupal.behaviors.jquery_loadinganimation.Loadinganimation.hide();
});
// Bei ESC wieder ausblenden
......@@ -66,7 +66,7 @@
keycode = e.which;
}
if (keycode == 27) { // escape, close box
Loadinganimation.hide();
Drupal.behaviors.jquery_loadinganimation.Loadinganimation.hide();
}
};
};
......@@ -74,11 +74,11 @@
// Initialize!
this._init(context);
// Register global Loadinganimation object after init!
Loadinganimation = this;
// Register global Drupal.behaviors.jquery_loadinganimation.Loadinganimation object after init!
Drupal.behaviors.jquery_loadinganimation.Loadinganimation = this;
// Preload images.
jQuery.preLoadImages(Drupal.settings.basePath + Loadinganimation.settings.img_src);
jQuery.preLoadImages(Drupal.settings.basePath + Drupal.settings.jquery_loadinganimation.img_src);
/**
* Zeigt die Ladegrafik als Layer über der Seite.
......@@ -89,15 +89,15 @@
$("body")
.append(
'<div id="loadinganimation"><div class="border top"></div><div class="inner"><img class="first" src="'
+ Drupal.settings.basePath + Loadinganimation.settings.img_src
+ Drupal.settings.basePath + Drupal.settings.jquery_loadinganimation.img_src
+ '" alt="'
+ Drupal.t('Loading')
+ '..." /><img class="second" src="'
+ Drupal.settings.basePath + Loadinganimation.settings.img_src
+ Drupal.settings.basePath + Drupal.settings.jquery_loadinganimation.img_src
+ '" alt="'
+ Drupal.t('Loading')
+ '..." /><img class="third" src="'
+ Drupal.settings.basePath + Loadinganimation.settings.img_src
+ Drupal.settings.basePath + Drupal.settings.jquery_loadinganimation.img_src
+ '" alt="'
+ Drupal.t('Loading')
+ '..." /><br />'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment