diff --git a/modules/navcarousel/controllers/admin_navcarousel.php b/modules/navcarousel/controllers/admin_navcarousel.php
index 77643fe7..5d9dff60 100644
--- a/modules/navcarousel/controllers/admin_navcarousel.php
+++ b/modules/navcarousel/controllers/admin_navcarousel.php
@@ -72,6 +72,8 @@ class Admin_Navcarousel_Controller extends Admin_Controller {
"navcarousel", "abovephoto", $form->navcarousel->abovephoto->value, true);
module::set_var(
"navcarousel", "noajax", $form->navcarousel->noajax->value, true);
+ module::set_var(
+ "navcarousel", "showondomready", $form->navcarousel->showondomready->value, true);
module::set_var(
"navcarousel", "maintainaspect", $form->thumbsettings->maintainaspect->value, true);
module::set_var(
@@ -109,6 +111,8 @@ class Admin_Navcarousel_Controller extends Admin_Controller {
->checked(module::get_var("navcarousel", "abovephoto", false));
$group->checkbox("noajax")->label(t("Disable dynamic loading of thumbnails (might be slow for big albums)"))
->checked(module::get_var("navcarousel", "noajax", false));
+ $group->checkbox("showondomready")->label(t("Show carousel before all items are loaded (faster loading on large albums but might cause too early display on Chrome and Opera)"))
+ ->checked(module::get_var("navcarousel", "showondomready", false));
$group = $form->group("thumbsettings")->label(t("Change how thumnails are displayed"));
$group->input("thumbsize")->label(t('Thumbnail size (in pixel)'))
diff --git a/modules/navcarousel/css/skin.css b/modules/navcarousel/css/skin.css
index 47a16180..695779f0 100644
--- a/modules/navcarousel/css/skin.css
+++ b/modules/navcarousel/css/skin.css
@@ -87,14 +87,12 @@
box-shadow: 1px 0px 8px #d7e1fa;
-moz-box-shadow: 1px 0px 8px #d7e1fa;
-webkit-box-shadow: 1px 0px 8px #d7e1fa;
- behavior: url(ie-css3.htc);
}
.carousel-current {
box-shadow: 1px 0px 8px #d7e1fa;
-moz-box-shadow: 1px 0px 8px #d7e1fa;
-webkit-box-shadow: 1px 0px 8px #d7e1fa;
- behavior: url(ie-css3.htc);
padding: 5px;
margin: 0 !important;
}
diff --git a/modules/navcarousel/helpers/navcarousel_theme.php b/modules/navcarousel/helpers/navcarousel_theme.php
index 5c757548..99853437 100644
--- a/modules/navcarousel/helpers/navcarousel_theme.php
+++ b/modules/navcarousel/helpers/navcarousel_theme.php
@@ -58,7 +58,12 @@ class navcarousel_theme_Core {
} else {
$ajaxhandler = "itemLoadCallback: navcarousel_itemLoadCallback,\n";
}
-
+ if (module::get_var("navcarousel", "showondomready", false)) {
+ $onwinload = "";
+ } else {
+ $onwinload = "});\n
+ $(window).load(function () {\n";
+ }
Return "\n
\n