From 65051a4bf77321518a0cf80bc328a7ed609dfc90 Mon Sep 17 00:00:00 2001 From: Tim Almdal Date: Wed, 23 Sep 2009 15:06:17 -0700 Subject: Rename the default themes to wind and admin_wind. Change xss_data.txt file to reflect this move. Not completely moved yet, but the git st is rather large so lets commit this now as a base for the cleanup. --- themes/admin_wind/js/ui.init.js | 59 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 themes/admin_wind/js/ui.init.js (limited to 'themes/admin_wind/js/ui.init.js') diff --git a/themes/admin_wind/js/ui.init.js b/themes/admin_wind/js/ui.init.js new file mode 100644 index 00000000..c6379c09 --- /dev/null +++ b/themes/admin_wind/js/ui.init.js @@ -0,0 +1,59 @@ +$(document).ready(function(){ + // Initialize Superfish menus + $("#gSiteAdminMenu ul.gMenu").addClass("sf-menu"); + $("ul.gMenu").addClass("sf-menu"); + $("ul.sf-menu").superfish({ + delay: 500, + animation: { + opacity: "show", + height: "show" + }, + pathClass: "current", + speed: "fast" + }); + $("#gSiteAdminMenu").css("display", "block"); + + // Initialize status message effects + $("#gMessage li").gallery_show_message(); + + // Initialize modal dialogs + $(".gDialogLink").gallery_dialog(); + + // Initialize ajax links + $(".gAjaxLink").gallery_ajax(); + + // Initialize panels + $(".gPanelLink").gallery_panel(); + + if ($("#gPhotoStream").length) { + // Vertically align thumbs in photostream + $(".gItem").gallery_valign(); + } + + // Apply jQuery UI button css to submit inputs + $("input[type=submit]:not(.gShortForm input)").addClass("ui-state-default ui-corner-all"); + + // Round view menu buttons + if ($("#gAdminCommentsMenu").length) { + $("#gAdminCommentsMenu ul").removeClass("gMenu").removeClass("sf-menu"); + $("#gAdminCommentsMenu").addClass("gButtonSet"); + $("#gAdminCommentsMenu a").addClass("gButtonLink ui-state-default"); + $("#gAdminCommentsMenu ul li:first a").addClass("ui-corner-left"); + $("#gAdminCommentsMenu ul li:last a").addClass("ui-corner-right"); + } + + // Round corners + $(".gSelected").addClass("ui-corner-all"); + $(".gAvailable .gBlock").addClass("ui-corner-all"); + $(".gUnavailable").addClass("ui-corner-all"); + + // Add hover state for buttons + $(".ui-state-default").hover( + function() { + $(this).addClass("ui-state-hover"); + }, + function() { + $(this).removeClass("ui-state-hover"); + } + ); +}); -- cgit v1.2.3 From 72672bda39b76dae698805c3e0e6efdbdcf21105 Mon Sep 17 00:00:00 2001 From: Chad Kieffer Date: Wed, 30 Sep 2009 08:04:49 -0600 Subject: Replaced gButtonLink with g-button. --- lib/gallery.common.css | 12 +++++++++++ modules/comment/views/admin_comments.html.php | 12 +++++------ modules/comment/views/comments.html.php | 2 +- modules/exif/views/exif_sidebar.html.php | 2 +- modules/g2_import/views/admin_g2_import.html.php | 2 +- modules/gallery/views/admin_graphics_gd.html.php | 4 ++-- .../views/admin_graphics_graphicsmagick.html.php | 2 +- .../views/admin_graphics_imagemagick.html.php | 2 +- modules/gallery/views/admin_languages.html.php | 2 +- modules/gallery/views/admin_maintenance.html.php | 18 ++++++++-------- modules/gallery/views/l10n_client.html.php | 2 +- modules/gallery/views/welcome_message.html.php | 2 +- modules/organize/views/organize_dialog.html.php | 2 +- modules/tag/views/admin_tags.html.php | 2 +- modules/user/views/admin_users.html.php | 10 ++++----- modules/user/views/admin_users_group.html.php | 6 +++--- modules/watermark/views/admin_watermarks.html.php | 6 +++--- themes/admin_wind/css/screen.css | 25 ++++++++-------------- themes/admin_wind/js/ui.init.js | 2 +- themes/admin_wind/views/pager.html.php | 16 +++++++------- themes/wind/css/screen.css | 15 ++++--------- themes/wind/js/ui.init.js | 2 +- themes/wind/views/movie.html.php | 8 +++---- themes/wind/views/pager.html.php | 16 +++++++------- themes/wind/views/photo.html.php | 8 +++---- 25 files changed, 89 insertions(+), 91 deletions(-) (limited to 'themes/admin_wind/js/ui.init.js') diff --git a/lib/gallery.common.css b/lib/gallery.common.css index 0aa9cc29..d57e95fc 100644 --- a/lib/gallery.common.css +++ b/lib/gallery.common.css @@ -138,6 +138,18 @@ form .g-error { } .g-button { + display: inline-block; + margin: 0 4px 0 0; + padding: .2em .4em; +} + +.g-button, +.g-button:hover, +.g-button:active { + cursor: pointer !important; + outline: 0; + text-decoration: none; + -moz-outline-style: none; } .g-progressbar { diff --git a/modules/comment/views/admin_comments.html.php b/modules/comment/views/admin_comments.html.php index 5e9ffb1a..ec5ad7b2 100644 --- a/modules/comment/views/admin_comments.html.php +++ b/modules/comment/views/admin_comments.html.php @@ -139,7 +139,7 @@ state != "unpublished"): ?>
  • + class="g-button ui-state-default ui-icon-left"> @@ -148,7 +148,7 @@ state != "published"): ?>
  • + class="g-button ui-state-default ui-icon-left"> @@ -157,7 +157,7 @@ state != "spam"): ?>
  • + class="g-button ui-state-default ui-icon-left"> @@ -166,14 +166,14 @@
  • + class="g-button ui-state-default ui-icon-left"> diff --git a/modules/comment/views/comments.html.php b/modules/comment/views/comments.html.php index dd706a23..ee4a8ad6 100644 --- a/modules/comment/views/comments.html.php +++ b/modules/comment/views/comments.html.php @@ -1,6 +1,6 @@ id})") ?>" id="gAddCommentButton" - class="gButtonLink ui-corner-all ui-icon-left ui-state-default right"> + class="g-button ui-corner-all ui-icon-left ui-state-default right"> diff --git a/modules/exif/views/exif_sidebar.html.php b/modules/exif/views/exif_sidebar.html.php index 60c0e1d4..23ecab03 100644 --- a/modules/exif/views/exif_sidebar.html.php +++ b/modules/exif/views/exif_sidebar.html.php @@ -1,6 +1,6 @@ id}") ?>" title="for_html_attr() ?>" - class="gDialogLink gButtonLink ui-icon-left ui-state-default ui-corner-all"> + class="gDialogLink g-button ui-icon-left ui-state-default ui-corner-all"> diff --git a/modules/g2_import/views/admin_g2_import.html.php b/modules/g2_import/views/admin_g2_import.html.php index 23ff27a8..91b723ad 100644 --- a/modules/g2_import/views/admin_g2_import.html.php +++ b/modules/g2_import/views/admin_g2_import.html.php @@ -84,7 +84,7 @@

    - "> diff --git a/modules/gallery/views/admin_graphics_gd.html.php b/modules/gallery/views/admin_graphics_gd.html.php index 010a31b4..08c19234 100644 --- a/modules/gallery/views/admin_graphics_gd.html.php +++ b/modules/gallery/views/admin_graphics_gd.html.php @@ -11,7 +11,7 @@ $tk->version)) ?>

    - +

    installed): ?> error): ?> @@ -20,7 +20,7 @@

    - +

    diff --git a/modules/gallery/views/admin_graphics_graphicsmagick.html.php b/modules/gallery/views/admin_graphics_graphicsmagick.html.php index 97624850..6ee15bc3 100644 --- a/modules/gallery/views/admin_graphics_graphicsmagick.html.php +++ b/modules/gallery/views/admin_graphics_graphicsmagick.html.php @@ -11,7 +11,7 @@ $tk->version, "dir" => $tk->dir)) ?>

    - +

    diff --git a/modules/gallery/views/admin_graphics_imagemagick.html.php b/modules/gallery/views/admin_graphics_imagemagick.html.php index cdff7c2c..aeef4919 100644 --- a/modules/gallery/views/admin_graphics_imagemagick.html.php +++ b/modules/gallery/views/admin_graphics_imagemagick.html.php @@ -11,7 +11,7 @@ $tk->version, "dir" => $tk->dir)) ?>

    - +

    error): ?>
    diff --git a/modules/gallery/views/admin_languages.html.php b/modules/gallery/views/admin_languages.html.php index fb30c7ba..d6f50516 100644 --- a/modules/gallery/views/admin_languages.html.php +++ b/modules/gallery/views/admin_languages.html.php @@ -88,7 +88,7 @@

    Step 3: Start the translation mode and the translation interface will appear at the bottom of each Gallery page.") ?>

    + class="g-button ui-state-default ui-corner-all ui-icon-left"> get("l10n_mode", false)): ?> diff --git a/modules/gallery/views/admin_maintenance.html.php b/modules/gallery/views/admin_maintenance.html.php index 00ba5199..8c3917b6 100644 --- a/modules/gallery/views/admin_maintenance.html.php +++ b/modules/gallery/views/admin_maintenance.html.php @@ -30,7 +30,7 @@ callback?csrf=$csrf") ?>" - class="gDialogLink gButtonLink ui-icon-left ui-state-default ui-corner-all"> + class="gDialogLink g-button ui-icon-left ui-state-default ui-corner-all"> @@ -62,7 +62,7 @@ " - class="gButtonLink g-right ui-icon-left ui-state-default ui-corner-all"> + class="g-button g-right ui-icon-left ui-state-default ui-corner-all"> @@ -96,11 +96,11 @@ id?csrf=$csrf") ?>" - class="gButtonLink g-right ui-icon-left ui-state-default ui-corner-all"> + class="g-button g-right ui-icon-left ui-state-default ui-corner-all"> state == "stalled"): ?> - id?csrf=$csrf") ?>"> @@ -135,7 +135,7 @@ " - class="gButtonLink g-right ui-icon-left ui-state-default ui-corner-all"> + class="g-button g-right ui-icon-left ui-state-default ui-corner-all"> @@ -166,19 +166,19 @@ done): ?> - id?csrf=$csrf") ?>" class="gButtonLink ui-state-default ui-corner-all"> + id?csrf=$csrf") ?>" class="g-button ui-state-default ui-corner-all"> get_log()): ?> - id?csrf=$csrf") ?>" class="gDialogLink gButtonLink ui-state-default ui-corner-all"> + id?csrf=$csrf") ?>" class="gDialogLink g-button ui-state-default ui-corner-all"> - id?csrf=$csrf") ?>" class="gDialogLink gButtonLink" ui-state-default ui-corner-all> + id?csrf=$csrf") ?>" class="gDialogLink g-button" ui-state-default ui-corner-all> - id?csrf=$csrf") ?>" class="gButtonLink ui-state-default ui-corner-all"> + id?csrf=$csrf") ?>" class="g-button ui-state-default ui-corner-all"> diff --git a/modules/gallery/views/l10n_client.html.php b/modules/gallery/views/l10n_client.html.php index b0f424be..a7f001aa 100644 --- a/modules/gallery/views/l10n_client.html.php +++ b/modules/gallery/views/l10n_client.html.php @@ -68,7 +68,7 @@
    for_html_attr() ?>"/> + class="g-button ui-state-default ui-corner-all"> diff --git a/modules/gallery/views/welcome_message.html.php b/modules/gallery/views/welcome_message.html.php index 5515c3dc..021e5772 100644 --- a/modules/gallery/views/welcome_message.html.php +++ b/modules/gallery/views/welcome_message.html.php @@ -18,7 +18,7 @@ id}") ?>" title="for_html_attr() ?>" id="gAfterInstallChangePasswordLink" - class="gButtonLink ui-state-default ui-corners-all"> + class="g-button ui-state-default ui-corners-all">
    " - class="gDialogLink gButtonLink g-right ui-icon-left ui-state-default ui-corner-all" + class="gDialogLink g-button g-right ui-icon-left ui-state-default ui-corner-all" title="for_html_attr() ?>"> @@ -85,15 +85,15 @@ id") ?>" open_text="" - class="gPanelLink gButtonLink ui-state-default ui-corner-all ui-icon-left"> + class="gPanelLink g-button ui-state-default ui-corner-all ui-icon-left"> id != $user->id && !$user->guest): ?> id") ?>" - class="gDialogLink gButtonLink ui-state-default ui-corner-all ui-icon-left"> + class="gDialogLink g-button ui-state-default ui-corner-all ui-icon-left"> for_html_attr() ?>" - class="gButtonLink ui-state-disabled ui-corner-all ui-icon-left"> + class="g-button ui-state-disabled ui-corner-all ui-icon-left"> @@ -105,7 +105,7 @@
    " - class="gDialogLink gButtonLink right ui-icon-left ui-state-default ui-corner-all" + class="gDialogLink g-button right ui-icon-left ui-state-default ui-corner-all" title="for_html_attr() ?>"> diff --git a/modules/user/views/admin_users_group.html.php b/modules/user/views/admin_users_group.html.php index 476e0817..6f2496f8 100644 --- a/modules/user/views/admin_users_group.html.php +++ b/modules/user/views/admin_users_group.html.php @@ -4,11 +4,11 @@ special): ?> id") ?>" title=" $group->name))->for_html_attr() ?>" - class="gDialogLink gButtonLink ui-state-default ui-corner-all"> + class="gDialogLink g-button ui-state-default ui-corner-all"> for_html_attr() ?>" - class="gDialogLink gButtonLink ui-state-disabled ui-corner-all ui-icon-left"> + class="gDialogLink g-button ui-state-disabled ui-corner-all ui-icon-left"> @@ -20,7 +20,7 @@ name) ?> special): ?> $user->name, "group" => $group->name))->for_html_attr() ?>"> diff --git a/modules/watermark/views/admin_watermarks.html.php b/modules/watermark/views/admin_watermarks.html.php index ac69d21d..3790030d 100644 --- a/modules/watermark/views/admin_watermarks.html.php +++ b/modules/watermark/views/admin_watermarks.html.php @@ -8,7 +8,7 @@ " title="for_html_attr() ?>" - class="gDialogLink gButtonLink ui-icon-left ui-state-default ui-corner-all"> + class="gDialogLink g-button ui-icon-left ui-state-default ui-corner-all">

    @@ -27,10 +27,10 @@

    " title="for_html_attr() ?>" - class="gDialogLink gButtonLink ui-icon-left ui-state-default ui-corner-all"> + class="gDialogLink g-button ui-icon-left ui-state-default ui-corner-all"> " title="for_html_attr() ?>" - class="gDialogLink gButtonLink ui-icon-left ui-state-default ui-corner-all"> + class="gDialogLink g-button ui-icon-left ui-state-default ui-corner-all">
    diff --git a/themes/admin_wind/css/screen.css b/themes/admin_wind/css/screen.css index d006463d..737c5939 100644 --- a/themes/admin_wind/css/screen.css +++ b/themes/admin_wind/css/screen.css @@ -68,9 +68,9 @@ h3 { a, .gMenu a, #gDialog a, -.gButtonLink, -.gButtonLink:hover, -.gButtonLink:active, +.g-button, +.g-button:hover, +.g-button:active, a.ui-state-hover, input.ui-state-hover, button.ui-state-hover { @@ -283,11 +283,11 @@ li.gError select { background: #eee; } -.gAvailable .gButtonLink { +.gAvailable .g-button { width: 96%; } -.gSelected .gButtonLink { +.gSelected .g-button { display: none; } @@ -627,7 +627,7 @@ li.gGroup h4 { border-bottom: 1px dashed #ccc; padding: .5em 0 .5em .5em; } -li.gGroup .gButtonLink { +li.gGroup .g-button { padding: 0; } li.gGroup ul, li.gGroup div { @@ -644,7 +644,7 @@ li.gGroup div p { li.gGroup .gUser { padding: .2em 0 0 .5em; } -li.gGroup .gUser .gButtonLink { +li.gGroup .gUser .g-button { vertical-align: middle; } @@ -838,13 +838,6 @@ li.gDefaultGroup h4, li.gDefaultGroup .gUser { /* jQuery UI ThemeRoller buttons */ -.gButtonLink { - display: inline-block; - margin: 0 4px 0 0; - padding: .2em .4em; - outline: 0; -} - .gButtonSet { padding-left: 1px; } @@ -853,7 +846,7 @@ li.gDefaultGroup h4, li.gDefaultGroup .gUser { float: left; } -.gButtonSet .gButtonLink { +.gButtonSet .g-button { margin: 0; } @@ -1106,7 +1099,7 @@ li.gDefaultGroup h4, li.gDefaultGroup .gUser { clear: both; } -#gTranslations .gButtonLink { +#gTranslations .g-button { padding: .5em; } diff --git a/themes/admin_wind/js/ui.init.js b/themes/admin_wind/js/ui.init.js index c6379c09..d9b011bd 100644 --- a/themes/admin_wind/js/ui.init.js +++ b/themes/admin_wind/js/ui.init.js @@ -37,7 +37,7 @@ $(document).ready(function(){ if ($("#gAdminCommentsMenu").length) { $("#gAdminCommentsMenu ul").removeClass("gMenu").removeClass("sf-menu"); $("#gAdminCommentsMenu").addClass("gButtonSet"); - $("#gAdminCommentsMenu a").addClass("gButtonLink ui-state-default"); + $("#gAdminCommentsMenu a").addClass("g-button ui-state-default"); $("#gAdminCommentsMenu ul li:first a").addClass("ui-corner-left"); $("#gAdminCommentsMenu ul li:last a").addClass("ui-corner-right"); } diff --git a/themes/admin_wind/views/pager.html.php b/themes/admin_wind/views/pager.html.php index 90c71446..29b9f9d0 100644 --- a/themes/admin_wind/views/pager.html.php +++ b/themes/admin_wind/views/pager.html.php @@ -10,34 +10,34 @@ "count" => $total_items)) ?>
  • - + - + - + - +
  • - + - + - + - +
  • diff --git a/themes/wind/css/screen.css b/themes/wind/css/screen.css index 9f3a53e6..6d955481 100644 --- a/themes/wind/css/screen.css +++ b/themes/wind/css/screen.css @@ -68,9 +68,9 @@ h3 { a, .gMenu a, #gDialog a, -.gButtonLink, -.gButtonLink:hover, -.gButtonLink:active, +.g-button, +.g-button:hover, +.g-button:active, a.ui-state-hover, input.ui-state-hover, button.ui-state-hover { @@ -884,13 +884,6 @@ form .gError, /* jQuery UI ThemeRoller buttons */ -.gButtonLink { - display: inline-block; - margin: 0 4px 0 0; - padding: .2em .4em; - outline: 0; -} - .gButtonSet { padding-left: 1px; } @@ -899,7 +892,7 @@ form .gError, float: left; } -.gButtonSet .gButtonLink { +.gButtonSet .g-button { margin: 0; } diff --git a/themes/wind/js/ui.init.js b/themes/wind/js/ui.init.js index c79e91bd..4a1962c0 100644 --- a/themes/wind/js/ui.init.js +++ b/themes/wind/js/ui.init.js @@ -49,7 +49,7 @@ $(document).ready(function() { // Apply styles and icon classes to gContextMenu if ($(".gContextMenu").length) { $(".gContextMenu li").addClass("ui-state-default"); - $(".gContextMenu a").addClass("gButtonLink ui-icon-left"); + $(".gContextMenu a").addClass("g-button ui-icon-left"); $(".gContextMenu a").prepend(""); $(".gContextMenu a span").each(function() { var iconClass = $(this).parent().attr("class").match(/ui-icon-.[^\s]+/).toString(); diff --git a/themes/wind/views/movie.html.php b/themes/wind/views/movie.html.php index 8b8e43a8..cf7c9b7f 100644 --- a/themes/wind/views/movie.html.php +++ b/themes/wind/views/movie.html.php @@ -5,20 +5,20 @@