summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
Diffstat (limited to 'modules')
-rw-r--r--modules/gallery/helpers/gallery_installer.php7
-rw-r--r--modules/gallery/libraries/Form_Uploadify.php8
-rw-r--r--modules/gallery/module.info3
-rw-r--r--modules/gallery/views/form_uploadify.html.php2
4 files changed, 10 insertions, 10 deletions
diff --git a/modules/gallery/helpers/gallery_installer.php b/modules/gallery/helpers/gallery_installer.php
index 57a5ee9f..39859b36 100644
--- a/modules/gallery/helpers/gallery_installer.php
+++ b/modules/gallery/helpers/gallery_installer.php
@@ -432,6 +432,13 @@ class gallery_installer {
module::clear_var("gallery", "blocks_site.sidebar");
module::set_version("gallery", $version = 19);
}
+
+ // Set a default for the number of simultaneous uploads
+ // Version 20 was reverted in 57adefc5baa7a2b0dfcd3e736e80c2fa86d3bfa2, so skip it.
+ if ($version == 19 || $version == 20) {
+ module::set_var("gallery", "simultaneous_upload_limit", 5);
+ module::set_version("gallery", $version = 21);
+ }
}
static function uninstall() {
diff --git a/modules/gallery/libraries/Form_Uploadify.php b/modules/gallery/libraries/Form_Uploadify.php
index 52fa45f0..9d76153d 100644
--- a/modules/gallery/libraries/Form_Uploadify.php
+++ b/modules/gallery/libraries/Form_Uploadify.php
@@ -45,13 +45,7 @@ class Form_Uploadify_Core extends Form_Input {
$v = new View("form_uploadify.html");
$v->album = $this->data["album"];
$v->script_data = $this->data["script_data"];
- $upload_limit = module::get_var("gallery", "upload_limit");
- if (empty($upload_limit)) {
- $upload_limit = 5;
- module::set_var("gallery", "upload_limit", 5);
- }
-
- $v->upload_limit = $upload_limit;
+ $v->simultaneous_upload_limit = module::get_var("gallery", "simultaneous_upload_limit");
return $v;
}
diff --git a/modules/gallery/module.info b/modules/gallery/module.info
index ba1ee91d..b3366f7d 100644
--- a/modules/gallery/module.info
+++ b/modules/gallery/module.info
@@ -1,5 +1,4 @@
name = "Gallery 3"
description = "Gallery core application"
-; Note: skip version 20, use 21 as the next version
-version = 19
+version = 21
diff --git a/modules/gallery/views/form_uploadify.html.php b/modules/gallery/views/form_uploadify.html.php
index c18bc8ca..d856c464 100644
--- a/modules/gallery/views/form_uploadify.html.php
+++ b/modules/gallery/views/form_uploadify.html.php
@@ -24,7 +24,7 @@
fileDesc: <?= t("Photos and movies")->for_js() ?>,
cancelImg: "<?= url::file("lib/uploadify/cancel.png") ?>",
buttonText: <?= t("Select photos...")->for_js() ?>,
- simUploadLimit: <?= $upload_limit ?>,
+ simUploadLimit: <?= $simultaneous_upload_limit ?>,
wmode: "transparent",
hideButton: true, /* should be true */
auto: true,