diff options
author | Bharat Mediratta <bharat@menalto.com> | 2009-05-09 19:03:00 +0000 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2009-05-09 19:03:00 +0000 |
commit | 1bfbae15f6a0f186d385c4ad073555de12c46e04 (patch) | |
tree | 33efd8ac8658c28d9347eb8cedf5627c3779c560 /modules/g2_import/views | |
parent | db465072f5a56b1a7334379a0cbb3c179ae26866 (diff) |
Usability and performance improvements
Significantly speed up the process by copying Gallery2 thumbnails and
resizes wherever possible instead of regenerating them. This requires
us to figure out the dimensions of the original G2 derivative and make
sure that it matches in some reasonable way.
To allow users to take advantage of this, calculate the optimal thumb
and resize size to set in G3 to match what was used in G2. While
we're at it, give the user some idea of how much data is available in
G2 to import.
Diffstat (limited to 'modules/g2_import/views')
-rw-r--r-- | modules/g2_import/views/admin_g2_import.html.php | 50 |
1 files changed, 48 insertions, 2 deletions
diff --git a/modules/g2_import/views/admin_g2_import.html.php b/modules/g2_import/views/admin_g2_import.html.php index 5c2cfa6d..329a55a8 100644 --- a/modules/g2_import/views/admin_g2_import.html.php +++ b/modules/g2_import/views/admin_g2_import.html.php @@ -12,10 +12,56 @@ <div id="gAdminG2Import"> <h1> <?= t("Import") ?> </h1> <div class="gSuccess"> - <?= t("Gallery version %version detected", array("version" => g2_import::version())) ?> + <p> + <?= t("Gallery version %version detected", array("version" => g2_import::version())) ?> + </p> </div> - <?= t("You can perform an import on the <a href=\"%url\">maintenance page</a>", + <div class="gInfo"> + <p> + <?= t("Your Gallery 2 has the following importable data in it") ?> + </p> + <ul> + <li> + <?= t2("1 user", "%count users", $g2_stats["users"]) ?> + </li> + <li> + <?= t2("1 group", "%count groups", $g2_stats["groups"]) ?> + </li> + <li> + <?= t2("1 album", "%count albums", $g2_stats["albums"]) ?> + </li> + <li> + <?= t2("1 photo", "%count photos", $g2_stats["photos"]) ?> + </li> + <li> + <?= t2("1 movie", "%count movies", $g2_stats["movies"]) ?> + </li> + <li> + <?= t2("1 comment", "%count comments", $g2_stats["comments"]) ?> + </li> + </ul> + </div> + + <? if ($thumb_size != $g2_sizes["thumb"]["size"]): ?> + <div class="gWarning"> + <?= t("Your most common thumbnail size in Gallery 2 is %g2_pixels pixels, but your Gallery 3 thumbnail size is set to %g3_pixels pixels. <a href=\"%url\">Using the same value</a> will speed up your import.", + array("g2_pixels" => $g2_sizes["thumb"]["size"], + "g3_pixels" => $thumb_size, + "url" => url::site("admin/theme_details"))) ?> + </div> + <? endif ?> + + <? if ($resize_size != $g2_sizes["resize"]["size"]): ?> + <div class="gWarning"> + <?= t("Your most common intermediate size in Gallery 2 is %g2_pixels pixels, but your Gallery 3 thumbnail size is set to %g3_pixels pixels. <a href=\"%url\">Using the same value</a> will speed up your import.", + array("g2_pixels" => $g2_sizes["resize"]["size"], + "g3_pixels" => $resize_size, + "url" => url::site("admin/theme_details"))) ?> + </div> + <? endif ?> + + <?= t("You can begin your import on the <a href=\"%url\">maintenance page</a>", array("url" => url::site("admin/maintenance"))) ?> </div> <? endif ?> |