summaryrefslogtreecommitdiff
path: root/modules/gallery/views
diff options
context:
space:
mode:
Diffstat (limited to 'modules/gallery/views')
-rw-r--r--modules/gallery/views/admin_block_welcome.html.php2
-rw-r--r--modules/gallery/views/admin_languages.html.php2
-rw-r--r--modules/gallery/views/admin_maintenance.html.php2
-rw-r--r--modules/gallery/views/admin_modules.html.php54
-rw-r--r--modules/gallery/views/admin_themes.html.php12
-rw-r--r--modules/gallery/views/admin_themes_buttonset.html.php48
-rw-r--r--modules/gallery/views/form_uploadify.html.php38
-rw-r--r--modules/gallery/views/movieplayer.html.php2
-rw-r--r--modules/gallery/views/upgrade_checker_block.html.php4
-rw-r--r--modules/gallery/views/upgrader.html.php2
10 files changed, 137 insertions, 29 deletions
diff --git a/modules/gallery/views/admin_block_welcome.html.php b/modules/gallery/views/admin_block_welcome.html.php
index d8c96187..d3765d19 100644
--- a/modules/gallery/views/admin_block_welcome.html.php
+++ b/modules/gallery/views/admin_block_welcome.html.php
@@ -2,7 +2,7 @@
<p>
<?= t("This is your administration dashboard and it provides a quick overview of status messages, recent updates, and frequently used options. Add or remove blocks and rearrange them to tailor to your needs. The admin menu provides quick access to all of Gallery 3's options and settings. Here are a few of the most used options to get you started.") ?>
</p>
-<ul>
+<ul class="g-text">
<li>
<?= t("General Settings - choose your <a href=\"%graphics_url\">graphics</a> and <a href=\"%language_url\">language</a> settings.",
array("graphics_url" => html::mark_clean(url::site("admin/graphics")),
diff --git a/modules/gallery/views/admin_languages.html.php b/modules/gallery/views/admin_languages.html.php
index 01d1ce3f..eef087e1 100644
--- a/modules/gallery/views/admin_languages.html.php
+++ b/modules/gallery/views/admin_languages.html.php
@@ -51,7 +51,7 @@
<? foreach ($available_locales as $code => $display_name): ?>
<? if ($i == (int) (count($available_locales)/2)): ?>
</table>
- <table>
+ <table class="g-left">
<tr>
<th> <?= t("Installed") ?> </th>
<th> <?= t("Language") ?> </th>
diff --git a/modules/gallery/views/admin_maintenance.html.php b/modules/gallery/views/admin_maintenance.html.php
index c28def1d..230e9353 100644
--- a/modules/gallery/views/admin_maintenance.html.php
+++ b/modules/gallery/views/admin_maintenance.html.php
@@ -3,7 +3,9 @@
<h1> <?= t("Maintenance") ?> </h1>
<div class="g-block-content">
<div id="g-maintenance-mode">
+ <p>
<?= t("When you're performing maintenance on your Gallery, you can enable <b>maintenance mode</b> which prevents any non-admin from accessing your Gallery. Some of the tasks below will automatically put your Gallery in maintenance mode for you.") ?>
+ </p>
<ul id="g-action-status" class="g-message-block">
<? if (module::get_var("gallery", "maintenance_mode")): ?>
<li class="g-warning">
diff --git a/modules/gallery/views/admin_modules.html.php b/modules/gallery/views/admin_modules.html.php
index f4ae965c..03993bb2 100644
--- a/modules/gallery/views/admin_modules.html.php
+++ b/modules/gallery/views/admin_modules.html.php
@@ -6,7 +6,7 @@
dataType: "json",
success: function(data) {
if (data.reload) {
- window.location.reload();
+ window.location = "<? url::site("/admin/modules") ?>";
} else {
$("body").append('<div id="g-dialog">' + data.dialog + '</div>');
$("#g-dialog").dialog({
@@ -43,7 +43,7 @@
</script>
<h1> <?= t("Gallery Modules") ?> </h1>
<p>
- <?= t("Power up your Gallery by adding more modules! Each module provides new cool features.") ?>
+ <?= t("Power up your Gallery by <a href=\"%url\">adding more modules</a>! Each module provides new cool features.", array("url" => "http://codex.gallery2.org/Category:Gallery_3:Modules")) ?>
</p>
<div class="g-block-content">
@@ -55,6 +55,7 @@
<th style="width: 8em"> <?= t("Name") ?> </th>
<th> <?= t("Version") ?> </th>
<th> <?= t("Description") ?> </th>
+ <th style="width: 60px"> <?= t("Details") ?> </th>
</tr>
<? foreach ($available as $module_name => $module_info): ?>
<tr class="<?= text::alternate("g-odd", "g-even") ?>">
@@ -64,6 +65,55 @@
<td> <?= t($module_info->name) ?> </td>
<td> <?= $module_info->version ?> </td>
<td> <?= t($module_info->description) ?> </td>
+ <td style="white-space: nowrap">
+ <ul class="g-buttonset">
+ <li>
+ <a target="_blank"
+ <? if (isset($module_info->author_url)): ?>
+ class="ui-state-default ui-icon ui-icon-person ui-corner-left"
+ href="<?= $module_info->author_url ?>"
+ <? else: ?>
+ class="ui-state-disabled ui-icon ui-icon-person ui-corner-left"
+ href="#"
+ <? endif ?>
+
+ <? if (isset($module_info->author_name)): ?>
+ title="<?= $module_info->author_name ?>"
+ <? endif ?>
+ >
+ <? if (isset($module_info->author_name)): ?>
+ <?= $module_info->author_name ?>
+ <? endif ?>
+ </a>
+ </li>
+ <li>
+ <a target="_blank"
+ <? if (isset($module_info->info_url)): ?>
+ class="ui-state-default ui-icon ui-icon-info"
+ href="<?= $module_info->info_url ?>"
+ <? else: ?>
+ class="ui-state-disabled ui-icon ui-icon-info"
+ href="#"
+ <? endif ?>
+ >
+ <?= t("info") ?>
+ </a>
+ </li>
+ <li>
+ <a target="_blank"
+ <? if (isset($module_info->discuss_url)): ?>
+ class="ui-state-default ui-icon ui-icon-comment ui-corner-right"
+ href="<?= $module_info->discuss_url ?>"
+ <? else: ?>
+ class="ui-state-disabled ui-icon ui-icon-comment ui-corner-right"
+ href="#"
+ <? endif ?>
+ >
+ <?= t("discuss") ?>
+ </a>
+ </li>
+ </ul>
+ </td>
</tr>
<? endforeach ?>
</table>
diff --git a/modules/gallery/views/admin_themes.html.php b/modules/gallery/views/admin_themes.html.php
index d14e8bd4..9d53779f 100644
--- a/modules/gallery/views/admin_themes.html.php
+++ b/modules/gallery/views/admin_themes.html.php
@@ -10,7 +10,7 @@
<div class="g-block ui-helper-clearfix">
<h1> <?= t("Theme choice") ?> </h1>
<p>
- <?= t("Gallery allows you to choose a theme for browsing your Gallery, as well as a special theme for the administration interface. Click a theme to preview and activate it.") ?>
+ <?= t("Make your Gallery beautiful <a href=\"%url\">with a new theme</a>! There are separate themes for the regular site and for the administration interface. Click a theme below to preview and activate it.", array("url" => "http://codex.gallery2.org/Category:Gallery_3:Themes")) ?>
</p>
<div class="g-block-content">
@@ -23,6 +23,7 @@
<p>
<?= $themes[$site]->description ?>
</p>
+ <? $v = new View("admin_themes_buttonset.html"); $v->info = $themes[$site]; print $v; ?>
</div>
<h2> <?= t("Available Gallery themes") ?> </h2>
@@ -40,13 +41,14 @@
<?= $info->description ?>
</p>
</a>
+ <? $v = new View("admin_themes_buttonset.html"); $v->info = $info; print $v; ?>
</div>
<? $count++ ?>
<? endforeach ?>
<? if (!$count): ?>
<p>
- <?= t("There are no other site themes available.") ?>
+ <?= t("There are no other site themes available. <a href=\"%url\">Download one now!</a>", array("url" => "http://codex.gallery2.org/Category:Gallery_3:Themes")) ?>
</p>
<? endif ?>
</div>
@@ -61,6 +63,7 @@
<p>
<?= $themes[$admin]->description ?>
</p>
+ <? $v = new View("admin_themes_buttonset.html"); $v->info = $themes[$admin]; print $v; ?>
</div>
<h2> <?= t("Available admin themes") ?> </h2>
@@ -78,17 +81,18 @@
<?= $info->description ?>
</p>
</a>
+ <? $v = new View("admin_themes_buttonset.html"); $v->info = $info; print $v; ?>
</div>
<? $count++ ?>
<? endforeach ?>
<? if (!$count): ?>
<p>
- <?= t("There are no other admin themes available.") ?>
+ <?= t("There are no other admin themes available. <a href=\"%url\">Download one now!</a>", array("url" => "http://codex.gallery2.org/Category:Gallery_3:Themes")) ?>
</p>
<? endif ?>
</div>
</div>
</div>
-</div> \ No newline at end of file
+</div>
diff --git a/modules/gallery/views/admin_themes_buttonset.html.php b/modules/gallery/views/admin_themes_buttonset.html.php
new file mode 100644
index 00000000..bf474a26
--- /dev/null
+++ b/modules/gallery/views/admin_themes_buttonset.html.php
@@ -0,0 +1,48 @@
+<?php defined("SYSPATH") or die("No direct script access.") ?>
+<ul class="g-buttonset">
+ <li>
+ <a target="_blank"
+ <? if (isset($info['author_url'])): ?>
+ class="ui-state-default ui-icon ui-icon-person ui-corner-left"
+ href="<?= $info['author_url'] ?>"
+ <? else: ?>
+ class="ui-state-disabled ui-icon ui-icon-person ui-corner-left"
+ href="#"
+ <? endif ?>
+
+ <? if (isset($info['author_name'])): ?>
+ title="<?= $info['author_name'] ?>"
+ <? endif ?>
+ >
+ <? if (isset($info['author_name'])): ?>
+ <?= $info['author_name'] ?>
+ <? endif ?>
+ </a>
+ </li>
+ <li>
+ <a target="_blank"
+ <? if (isset($info['info_url'])): ?>
+ class="ui-state-default ui-icon ui-icon-info"
+ href="<?= $info['info_url'] ?>"
+ <? else: ?>
+ class="ui-state-disabled ui-icon ui-icon-info"
+ href="#"
+ <? endif ?>
+ >
+ <?= t("info") ?>
+ </a>
+ </li>
+ <li>
+ <a target="_blank"
+ <? if (isset($info['discuss_url'])): ?>
+ class="ui-state-default ui-icon ui-icon-comment ui-corner-right"
+ href="<?= $info['discuss_url'] ?>"
+ <? else: ?>
+ class="ui-state-disabled ui-icon ui-icon-comment ui-corner-right"
+ href="#"
+ <? endif ?>
+ >
+ <?= t("discuss") ?>
+ </a>
+ </li>
+</ul>
diff --git a/modules/gallery/views/form_uploadify.html.php b/modules/gallery/views/form_uploadify.html.php
index 77b6d493..ba4a3621 100644
--- a/modules/gallery/views/form_uploadify.html.php
+++ b/modules/gallery/views/form_uploadify.html.php
@@ -28,10 +28,11 @@
uploader: "<?= url::file("lib/uploadify/uploadify.swf") ?>",
script: "<?= url::site("uploader/add_photo/{$album->id}") ?>",
scriptData: <?= json_encode($script_data) ?>,
- fileExt: "*.gif;*.jpg;*.jpeg;*.png;*.GIF;*.JPG;*.JPEG;*.PNG<? if ($movies_allowed): ?>;*.flv;*.mp4;*.m4v;*.FLV;*.MP4;*.M4V<? endif ?>",
+ fileExt: "<?= implode(";", $extensions) ?>",
fileDesc: <?= t("Photos and movies")->for_js() ?>,
cancelImg: "<?= url::file("lib/uploadify/cancel.png") ?>",
simUploadLimit: <?= $simultaneous_upload_limit ?>,
+ sizeLimit: <?= $size_limit_bytes ?>,
wmode: "transparent",
hideButton: true, /* should be true */
auto: true,
@@ -66,26 +67,30 @@
return true;
},
onError: function(event, queueID, fileObj, errorObj) {
- var msg = " - ";
if (errorObj.type == "HTTP") {
if (errorObj.info == "500") {
- msg += <?= t("Unable to process this file")->for_js() ?>;
- // Server error - check server logs
+ error_msg = <?= t("Unable to process this photo")->for_js() ?>;
} else if (errorObj.info == "404") {
- msg += <?= t("The upload script was not found.")->for_js() ?>;
- // Server script not found
+ error_msg = <?= t("The upload script was not found")->for_js() ?>;
+ } else if (errorObj.info == "400") {
+ error_msg = <?= t("This photo is too large (max is %size bytes)",
+ array("size" => $size_limit))->for_js() ?>;
} else {
- // Server Error: status: errorObj.info
- msg += (<?= t("Server error: __INFO__")->for_js() ?>.replace("__INFO__", errorObj.info));
+ msg += (<?= t("Server error: __INFO__ (__TYPE__)")->for_js() ?>
+ .replace("__INFO__", errorObj.info)
+ .replace("__TYPE__", errorObj.type));
}
} else if (errorObj.type == "File Size") {
- var sizelimit = $("#g-uploadify").uploadifySettings(sizeLimit);
- msg += fileObj.name+' '+errorObj.type+' Limit: '+Math.round(d.sizeLimit/1024)+'KB';
+ error_msg = <?= t("This photo is too large (max is %size bytes)",
+ array("size" => $size_limit))->for_js() ?>;
} else {
- msg += (<?= t("Server error: __INFO__ (__TYPE__)")->for_js() ?>
- .replace("__INFO__", errorObj.info)
- .replace("__TYPE__", errorObj.type));
+ error_msg = <?= t("Server error: __INFO__ (__TYPE__)")->for_js() ?>
+ .replace("__INFO__", errorObj.info)
+ .replace("__TYPE__", errorObj.type);
}
+ msg = " - <a target=\"_blank\" href=\"http://codex.gallery2.org/Gallery3:Troubleshooting:Uploading\">" +
+ error_msg + "</a>";
+
$("#g-add-photos-status ul").append(
"<li id=\"q" + queueID + "\" class=\"g-error\">" + fileObj.name + msg + "</li>");
$("#g-uploadify").uploadifyCancel(queueID);
@@ -131,10 +136,7 @@
<? endif ?>
<div>
- <p>
- <?= t("Photos will be uploaded to album: ") ?>
- </p>
- <ul class="g-breadcrumbs ui-helper-clearfix">
+ <ul class="g-breadcrumbs">
<? foreach ($album->parents() as $i => $parent): ?>
<li<? if ($i == 0) print " class=\"g-first\"" ?>> <?= html::clean($parent->title) ?> </li>
<? endforeach ?>
@@ -143,7 +145,7 @@
</div>
<div id="g-add-photos-canvas">
- <button id="g-add-photos-button" class="g-button ui-state-default ui-corner-all" href="#"><?= t("Select photos...") ?></button>
+ <button id="g-add-photos-button" class="g-button ui-state-default ui-corner-all" href="#"><?= t("Select photos (%size max per file)...", array("size" => $size_limit)) ?></button>
<span id="g-uploadify"></span>
</div>
<div id="g-add-photos-status">
diff --git a/modules/gallery/views/movieplayer.html.php b/modules/gallery/views/movieplayer.html.php
index 5c280a36..96d6532c 100644
--- a/modules/gallery/views/movieplayer.html.php
+++ b/modules/gallery/views/movieplayer.html.php
@@ -22,5 +22,5 @@
}
}
}
- )
+ ).ipad();
</script>
diff --git a/modules/gallery/views/upgrade_checker_block.html.php b/modules/gallery/views/upgrade_checker_block.html.php
index b04887b2..c984d99f 100644
--- a/modules/gallery/views/upgrade_checker_block.html.php
+++ b/modules/gallery/views/upgrade_checker_block.html.php
@@ -6,8 +6,10 @@
<p>
<? if (gallery::RELEASE_CHANNEL == "release"): ?>
<?= t("You are using the official Gallery %version release, code named <i>%code_name</i>.", array("version" => gallery::VERSION, "code_name" => gallery::CODE_NAME)) ?>
+ <? elseif (isset($build_number)): ?>
+ <?= t("You are using an experimental snapshot of Gallery %version (build %build_number on branch %branch).", array("version" => gallery::VERSION, "branch" => gallery::RELEASE_BRANCH, "build_number" => $build_number)) ?>
<? else: ?>
- <?= t("You are using an experimental snapshot of Gallery %version (build %build_number on branch %branch).", array("version" => gallery::VERSION, "branch" => gallery::RELEASE_BRANCH, "build_number" => gallery::build_number())) ?>
+ <?= t("You are using an experimental snapshot of Gallery %version (branch %branch) but your gallery3/.build_number file is missing so we don't know what build you have. You should probably upgrade so that you have that file.", array("version" => gallery::VERSION, "branch" => gallery::RELEASE_BRANCH, "build_number" => $build_number)) ?>
<? endif ?>
</p>
diff --git a/modules/gallery/views/upgrader.html.php b/modules/gallery/views/upgrader.html.php
index ad2e3421..70d37dd1 100644
--- a/modules/gallery/views/upgrader.html.php
+++ b/modules/gallery/views/upgrader.html.php
@@ -27,7 +27,7 @@
<div id="done" style="display: none">
<h1> <?= t("That's it!") ?> </h1>
<p>
- <?= t("Your <a href=\"%url\">Gallery</a> is up to date.",
+ <?= t("Your Gallery is up to date.<br/><a href=\"%url\">Return to your Gallery</a>",
array("url" => html::mark_clean(url::base()))) ?>
</p>
</div>