diff options
author | Bharat Mediratta <bharat@menalto.com> | 2011-04-23 14:43:33 -0700 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2011-04-23 14:43:33 -0700 |
commit | a469146084e7ba064f171609849c4d8590424f88 (patch) | |
tree | 0ec5ac816cfbe9b52a49a22d6b47b72781056e0d /modules/gallery/views | |
parent | cab5f15c319c4ae1ebf261fb1b5c172032957733 (diff) |
module.info and theme.info files now support author name, author url,
info url and discussion url fields. Those fields show up in the Admin
> Modules and Admin > Appearance > Theme Choice pages. All official
modules and themes updated to contain these values. Fixes #1696, #1698.
Diffstat (limited to 'modules/gallery/views')
-rw-r--r-- | modules/gallery/views/admin_modules.html.php | 52 | ||||
-rw-r--r-- | modules/gallery/views/admin_themes.html.php | 12 | ||||
-rw-r--r-- | modules/gallery/views/admin_themes_buttonset.html.php | 47 |
3 files changed, 106 insertions, 5 deletions
diff --git a/modules/gallery/views/admin_modules.html.php b/modules/gallery/views/admin_modules.html.php index 2cc81b0d..ecd51d30 100644 --- a/modules/gallery/views/admin_modules.html.php +++ b/modules/gallery/views/admin_modules.html.php @@ -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> <?= 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..7d947b28 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:Modules")) ?> </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:Modules")) ?> </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..5166f36c --- /dev/null +++ b/modules/gallery/views/admin_themes_buttonset.html.php @@ -0,0 +1,47 @@ + <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> |