diff options
author | Bharat Mediratta <bharat@menalto.com> | 2009-06-16 23:51:39 -0700 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2009-06-16 23:51:39 -0700 |
commit | 2531f679902e5e4bc5237017debb468c722d6b15 (patch) | |
tree | b7ee122cbb75babc4e1d7d6ebaba2f38d98b7c65 | |
parent | 5eeb6296a12127cda3c43e749c2bd854a251f94a (diff) | |
parent | 1dccc0286f3d983352e21f8148fdf4d9e9bc205d (diff) |
Merge branch 'master' of git@github.com:gallery/gallery3
-rw-r--r-- | modules/gallery/controllers/albums.php | 2 | ||||
-rw-r--r-- | modules/gallery/controllers/l10n_client.php | 14 | ||||
-rw-r--r-- | modules/gallery/views/l10n_client.html.php | 6 | ||||
-rw-r--r-- | themes/admin_default/views/pager.html.php | 32 | ||||
-rw-r--r-- | themes/default/views/page.html.php | 2 |
5 files changed, 43 insertions, 13 deletions
diff --git a/modules/gallery/controllers/albums.php b/modules/gallery/controllers/albums.php index 856709c2..17fdec6b 100644 --- a/modules/gallery/controllers/albums.php +++ b/modules/gallery/controllers/albums.php @@ -26,7 +26,7 @@ class Albums_Controller extends Items_Controller { $page_size = module::get_var("gallery", "page_size", 9); if (!access::can("view", $album)) { if ($album->id == 1) { - $view = new Theme_View("page.html", "page"); + $view = new Theme_View("page.html", "login"); $view->page_title = t("Log in to Gallery"); $view->content = user::get_login_form("login/auth_html"); print $view; diff --git a/modules/gallery/controllers/l10n_client.php b/modules/gallery/controllers/l10n_client.php index aa93a758..831c79c1 100644 --- a/modules/gallery/controllers/l10n_client.php +++ b/modules/gallery/controllers/l10n_client.php @@ -106,7 +106,19 @@ class L10n_Client_Controller extends Controller { } public static function l10n_form() { - $calls = I18n::instance()->call_log(); + if (Input::instance()->get("show_all_l10n_messages")) { + $calls = array(); + foreach (Database::instance() + ->select("key", "message") + ->from("incoming_translations") + ->where(array("locale" => 'root')) + ->get() + ->as_array() as $row) { + $calls[$row->key] = array(unserialize($row->message), array()); + } + } else { + $calls = I18n::instance()->call_log(); + } $locale = I18n::instance()->locale(); if ($calls) { diff --git a/modules/gallery/views/l10n_client.html.php b/modules/gallery/views/l10n_client.html.php index 2e53f48f..01537e25 100644 --- a/modules/gallery/views/l10n_client.html.php +++ b/modules/gallery/views/l10n_client.html.php @@ -2,7 +2,11 @@ <div id="l10n-client" class="hidden"> <div class="labels"> <span class="toggle"><?= t("Translate Text") ?></span> - <div class="label strings"><h2><?= t("Page Text") ?></h2></div> + <div class="label strings"><h2><?= t("Page Text") ?> + <? if (!Input::instance()->get('show_all_l10n_messages')): ?> + <a style="background-color:#fff" href="<?= url::site("admin/languages?show_all_l10n_messages=1") ?>"><?= t("(Show All)") ?></a> + <? endif; ?> + </h2></div> <div class="label source"><h2><?= t("Source") ?></div> <div class="label translation"><h2><?= t("Translation to %language", array("language" => locale::display_name())) ?></h2></div> diff --git a/themes/admin_default/views/pager.html.php b/themes/admin_default/views/pager.html.php index 505e8cf0..8df1b030 100644 --- a/themes/admin_default/views/pager.html.php +++ b/themes/admin_default/views/pager.html.php @@ -1,30 +1,42 @@ <?php defined("SYSPATH") or die("No direct script access.") ?> <? // See http://docs.kohanaphp.com/libraries/pagination ?> -<ul id="gPager"> +<ul class="gPager"> <? /* XXX: This message isn't easily localizable */ $from_to_msg = t("Items %from_number - %to_number of %total", array("from_number" => $current_first_item, "to_number" => $current_last_item, "total" => $total_items)) ?> - <li><?= $from_to_msg ?></li> + <li> <? if ($first_page): ?> - <li><span class="ui-icon ui-icon-seek-first"></span><a href="<?= str_replace('{page}', 1, $url) ?>"><?= t("first") ?></a></li> + <a href="<?= str_replace('{page}', 1, $url) ?>" class="gButtonLink ui-icon-left ui-state-default ui-corner-all"> + <span class="ui-icon ui-icon-seek-first"></span><?= t("first") ?></a> <? else: ?> - <li class="inactive"><span class="ui-icon ui-icon-seek-first"></span><?= t("first") ?></li> + <a class="gButtonLink ui-icon-left ui-state-disabled ui-corner-all"> + <span class="ui-icon ui-icon-seek-first"></span><?= t("first") ?></a> <? endif ?> <? if ($previous_page): ?> - <li><span class="ui-icon ui-icon-seek-prev"></span><a href="<?= str_replace('{page}', $previous_page, $url) ?>"><?= t("previous") ?></a></li> + <a href="<?= str_replace('{page}', $previous_page, $url) ?>" class="gButtonLink ui-icon-left ui-state-default ui-corner-all"> + <span class="ui-icon ui-icon-seek-prev"></span><?= t("previous") ?></a> <? else: ?> - <li class="inactive"><span class="ui-icon ui-icon-seek-prev"></span><?= t("previous") ?></li> + <a class="gButtonLink ui-icon-left ui-state-disabled ui-corner-all"> + <span class="ui-icon ui-icon-seek-prev"></span><?= t("previous") ?></a> <? endif ?> + </li> + <li class="gInfo"><?= $from_to_msg ?></li> + <li class="txtright"> <? if ($next_page): ?> - <li><a href="<?= str_replace('{page}', $next_page, $url) ?>"><?= t("next") ?></a><span class="ui-icon ui-icon-seek-next"></span></li> + <a href="<?= str_replace('{page}', $next_page, $url) ?>" class="gButtonLink ui-icon-right ui-state-default ui-corner-all"> + <span class="ui-icon ui-icon-seek-next"></span><?= t("next") ?></a> <? else: ?> - <li class="inactive"><?= t("next") ?><span class="ui-icon ui-icon-seek-next"></span></li> + <a class="gButtonLink ui-state-disabled ui-icon-right ui-corner-all"> + <span class="ui-icon ui-icon-seek-next"></span><?= t("next") ?></a> <? endif ?> <? if ($last_page): ?> - <li><a href="<?= str_replace('{page}', $last_page, $url) ?>"><?= t("last") ?></a><span class="ui-icon ui-icon-seek-end"></span></li> + <a href="<?= str_replace('{page}', $last_page, $url) ?>" class="gButtonLink ui-icon-right ui-state-default ui-corner-all"> + <span class="ui-icon ui-icon-seek-end"></span><?= t("last") ?></a> <? else: ?> - <li class="inactive"><?= t("last") ?><span class="ui-icon ui-icon-seek-end"></span></li> + <a class="gButtonLink ui-state-disabled ui-icon-right ui-corner-all"> + <span class="ui-icon ui-icon-seek-end"></span><?= t("last") ?></a> <? endif ?> + </li> </ul> diff --git a/themes/default/views/page.html.php b/themes/default/views/page.html.php index 3feb14cb..f6286f95 100644 --- a/themes/default/views/page.html.php +++ b/themes/default/views/page.html.php @@ -81,7 +81,9 @@ </div> </div> <div id="gSidebar" class="yui-b"> + <? if ($theme->page_type != "login"): ?> <?= $theme->display("sidebar.html") ?> + <? endif ?> </div> </div> <div id="gFooter"> |