summaryrefslogtreecommitdiff
path: root/modules/gallery
diff options
context:
space:
mode:
authorjhilden <jakobhilden@gmail.com>2009-08-29 14:21:53 -0400
committerjhilden <jakobhilden@gmail.com>2009-08-29 14:21:53 -0400
commit8d256898c7533f2d61e2c0672f70314c68cd0187 (patch)
treea114e30899da8aac4704d47a7f217d059d2a93c4 /modules/gallery
parent1527f149a90a46428c48b4b811d4b8ecc10b9d2c (diff)
improved translation interface so that it now can be closed without going to the admin
Diffstat (limited to 'modules/gallery')
-rw-r--r--modules/gallery/css/l10n_client.css12
-rw-r--r--modules/gallery/js/l10n_client.js7
-rw-r--r--modules/gallery/views/l10n_client.html.php5
3 files changed, 18 insertions, 6 deletions
diff --git a/modules/gallery/css/l10n_client.css b/modules/gallery/css/l10n_client.css
index 51cbc753..9c1b12d0 100644
--- a/modules/gallery/css/l10n_client.css
+++ b/modules/gallery/css/l10n_client.css
@@ -42,9 +42,17 @@
cursor:pointer;
display:block;
position:absolute; right:0em;
- padding: 0em .75em; height:2em; line-height:2em;
+ height:2em; line-height:2em;
text-transform:uppercase;
- text-align:center; background:#000;}
+ text-align:center; background:#000;
+}
+#l10n-client-toggler a {
+ font-size: 1em;
+ padding: .5em;
+}
+#l10n-client-toggler #gMinimizeL10n {
+ border-right: 1px solid #ffffff;
+}
/* Panel labels */
#l10n-client h2 {
diff --git a/modules/gallery/js/l10n_client.js b/modules/gallery/js/l10n_client.js
index f5be5058..80fe166b 100644
--- a/modules/gallery/js/l10n_client.js
+++ b/modules/gallery/js/l10n_client.js
@@ -58,7 +58,8 @@ jQuery.extend(Gallery, {
case 1:
$('#l10n-client-string-select, #l10n-client-string-editor, #l10n-client .labels .label').show();
$('#l10n-client').height('22em').removeClass('hidden');
- $('#l10n-client-toggler').text(MSG_CLOSE_X);
+ //$('#l10n-client').slideUp();
+ $('#gMinimizeL10n').text("_");
/*
* This CSS clashes with Gallery's CSS, probably due to
* YUI's grid / floats.
@@ -72,7 +73,7 @@ jQuery.extend(Gallery, {
$('#l10n-client-string-select, #l10n-client-string-editor, #l10n-client .labels .label').hide();
$('#l10n-client').height('2em').addClass('hidden');
// TODO: Localize this message
- $('#l10n-client-toggler').text(MSG_TRANSLATE_TEXT);
+ $('#gMinimizeL10n').text(MSG_TRANSLATE_TEXT);
/*
if(!$.browser.msie) {
$('body').css('border-bottom', '0px');
@@ -197,7 +198,7 @@ Gallery.behaviors.l10nClient = function(context) {
});
// When l10n_client window is clicked, toggle based on current state.
- $('#l10n-client-toggler').click(function() {
+ $('#gMinimizeL10n').click(function() {
if($('#l10n-client').is('.hidden')) {
Gallery.l10nClient.toggle(1);
} else {
diff --git a/modules/gallery/views/l10n_client.html.php b/modules/gallery/views/l10n_client.html.php
index c73719ca..5ee7eca3 100644
--- a/modules/gallery/views/l10n_client.html.php
+++ b/modules/gallery/views/l10n_client.html.php
@@ -1,7 +1,10 @@
<?php defined("SYSPATH") or die("No direct script access.") ?>
<div id="l10n-client" class="hidden">
<div class="labels">
- <span id="l10n-client-toggler">X</span>
+ <span id="l10n-client-toggler">
+ <a id="gMinimizeL10n">_</a>
+ <a id="gCloseL10n" href="<?= url::site("l10n_client/toggle_l10n_mode?csrf=".access::csrf_token()) ?>">X</a>
+ </span>
<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>