From 3ab6c4915aa0c9dbd2061ffcad0af00e2c50136e Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Mon, 11 Jan 2010 10:42:39 -0800 Subject: Fixes ticket #671. In the graphics_rules table height and width set the maximum height and width values and should be equal. Initially, the height on the resize target rule was less than the height, which artificially constrained images in portrait mode. **Note"" this fix requires an upgrade to version 22. All the resizes will be flagged dirty. --- modules/gallery/helpers/gallery_installer.php | 19 ++++++++++++++++++- modules/gallery/module.info | 2 +- 2 files changed, 19 insertions(+), 2 deletions(-) (limited to 'modules') diff --git a/modules/gallery/helpers/gallery_installer.php b/modules/gallery/helpers/gallery_installer.php index 410b6413..02ce1b18 100644 --- a/modules/gallery/helpers/gallery_installer.php +++ b/modules/gallery/helpers/gallery_installer.php @@ -240,7 +240,7 @@ class gallery_installer { 100); graphics::add_rule( "gallery", "resize", "gallery_graphics::resize", - array("width" => 640, "height" => 480, "master" => Image::AUTO), + array("width" => 640, "height" => 640, "master" => Image::AUTO), 100); // Instantiate default themes (site and admin) @@ -440,6 +440,23 @@ class gallery_installer { module::set_var("gallery", "simultaneous_upload_limit", 5); module::set_version("gallery", $version = 21); } + + // Update the graphics rules table so that the maximum height for resizes is 640 not 480. + // Fixes ticket #671 + if ( $version == 21) { + $resize_rule = ORM::factory("graphics_rule") + ->where("id", "=", "2") + ->find(); + // make sure it hasn't been changed already + $args = unserialize($resize_rule->args); + if ($args["height"] == 480 && $args["width"] == 640) { + $args["height"] = 640; + $resize_rule->args = serialize($args); + $resize_rule->save(); + graphics::mark_dirty(false, true); + } + module::set_version("gallery", $version = 22); + } } static function uninstall() { diff --git a/modules/gallery/module.info b/modules/gallery/module.info index b3366f7d..107d9a12 100644 --- a/modules/gallery/module.info +++ b/modules/gallery/module.info @@ -1,4 +1,4 @@ name = "Gallery 3" description = "Gallery core application" -version = 21 +version = 22 -- cgit v1.2.3 From 284e14d50e33fb6a1ef0ce00444f216fcdbeb904 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Mon, 11 Jan 2010 10:48:27 -0800 Subject: Remove the automatically marking the resizes dirty line as this could cause alot of pain to some installations --- modules/gallery/helpers/gallery_installer.php | 1 - 1 file changed, 1 deletion(-) (limited to 'modules') diff --git a/modules/gallery/helpers/gallery_installer.php b/modules/gallery/helpers/gallery_installer.php index 02ce1b18..1e0ad28c 100644 --- a/modules/gallery/helpers/gallery_installer.php +++ b/modules/gallery/helpers/gallery_installer.php @@ -453,7 +453,6 @@ class gallery_installer { $args["height"] = 640; $resize_rule->args = serialize($args); $resize_rule->save(); - graphics::mark_dirty(false, true); } module::set_version("gallery", $version = 22); } -- cgit v1.2.3 From 2b283f4d011a7a67f306e11e590b499242a0774b Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Mon, 11 Jan 2010 13:26:10 -0800 Subject: Remove the translation submit button from translation search form. Fixes ticket #975 --- modules/gallery/controllers/l10n_client.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'modules') diff --git a/modules/gallery/controllers/l10n_client.php b/modules/gallery/controllers/l10n_client.php index 71df1cf1..d22b6299 100644 --- a/modules/gallery/controllers/l10n_client.php +++ b/modules/gallery/controllers/l10n_client.php @@ -102,10 +102,9 @@ class L10n_Client_Controller extends Controller { } private static function _l10n_client_search_form() { - $form = new Forge("l10n_client/search", "", "post", array("id" => "g-l10n-search-form")); + $form = new Forge("#", "", "post", array("id" => "g-l10n-search-form")); $group = $form->group("l10n_search"); $group->input("l10n-search")->id("g-l10n-search"); - $group->submit("l10n-search-filter-clear")->value(t("X")); return $form; } -- cgit v1.2.3 From 3b26d87f3a8fdcf4dc0b86e2b2d72476356c411a Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Mon, 11 Jan 2010 14:22:16 -0800 Subject: Reformat the string list so that the search box does not get push off the end of the page. --- modules/gallery/css/l10n_client.css | 30 ++++++++++++++++++++---------- 1 file changed, 20 insertions(+), 10 deletions(-) (limited to 'modules') diff --git a/modules/gallery/css/l10n_client.css b/modules/gallery/css/l10n_client.css index 542da8e6..3771c049 100644 --- a/modules/gallery/css/l10n_client.css +++ b/modules/gallery/css/l10n_client.css @@ -86,7 +86,7 @@ } #l10n-client .string-list { - height:17em; + height: 16em; overflow:auto; list-style:none; list-style-image:none; margin:0em; padding:0em;} @@ -129,10 +129,9 @@ font-weight:bold;} #l10n-client #g-l10n-search-form { - background:#eee; - text-align:center; - height:2em; line-height:2em; - margin:0em; padding:.5em .5em; + background: #eee; + margin: 0em; + padding: .25em .25em; } #l10n-client #g-l10n-search-form .form-item, @@ -148,8 +147,14 @@ padding:0em; } -#l10n-client #g-l10n-search-form input.form-text { - width:80%; +#l10n-client #g-l10n-search-form fieldset { + margin-bottom: 0; + padding: .25em .25em; +} + + +#l10n-client #g-l10n-search-form input { + width: 96.75%; } #l10n-client #g-l10n-search-form #search-filter-clear { @@ -164,7 +169,9 @@ #l10n-client-string-editor .source { overflow:hidden; - width:50%; float:left;} + width:50%; + float:left; +} #l10n-client-string-editor .source .source-text { line-height:1.5em; @@ -178,10 +185,13 @@ #l10n-client-string-editor .translation { overflow:hidden; - width:49%; float:right;} + width:49%; + float: right; +} #g-l10n-client-save-form { - padding:0em;} + padding: 0em; +} #l10n-client form ul, #l10n-client form li, -- cgit v1.2.3 From 3dfac5884ff0661d680293f9888f9ab42e9ebd19 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Tue, 12 Jan 2010 08:31:28 -0800 Subject: Add a css id attribute to the i10n-edit-translation element. Fixes ticket #969. --- modules/gallery/views/l10n_client.html.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules') diff --git a/modules/gallery/views/l10n_client.html.php b/modules/gallery/views/l10n_client.html.php index 9d14bbb2..47a45e29 100644 --- a/modules/gallery/views/l10n_client.html.php +++ b/modules/gallery/views/l10n_client.html.php @@ -40,7 +40,7 @@
" id="g-l10n-client-save-form"> - +