# HG changeset patch # User Dan # Date 1238897852 14400 # Node ID 7e933a5c860b7080c4f0cd5494d38c79597460bd # Parent 35db370104ab78ff3334842fe72cdd0a7cfc1f0c Made aclDisableTransitionFX also switch on jQuery.fx.off; made theme switcher work with said jQuery switch diff -r 35db370104ab -r 7e933a5c860b includes/clientside/static/ajax.js --- a/includes/clientside/static/ajax.js Sat Apr 04 22:16:30 2009 -0400 +++ b/includes/clientside/static/ajax.js Sat Apr 04 22:17:32 2009 -0400 @@ -145,7 +145,7 @@ setTimeout(function() { box.focus(); - }, 200); + }, ( aclDisableTransitionFX ? 200 : 750 )); } window.ajaxRenameSubmit = function(obj) @@ -154,9 +154,10 @@ if ( !box ) return false; - var input = obj.getElementsByTagName('input')[0]; + var input = box.getElementsByTagName('input')[0]; if ( !input ) return false; + var newname = input.value; newname = trim(newname); @@ -762,7 +763,8 @@ $('#theme-selector-body').animate({ width: 708 }, 600, function() { // avoiding jQuery's fade functions because they insist on toggling display as well - changeOpac(0, 'theme-selector-inner'); + if ( !aclDisableTransitionFX ) + changeOpac(0, 'theme-selector-inner'); $('#theme-selector-inner').html('

'); $('#theme-selector-inner > h3').text($lang.get('ajax_thmsel_lbl_choosetheme')); $('#theme-selector-inner').append(''); @@ -781,7 +783,8 @@ $('#theme-selector-body').animate({ height: $('#theme-selector-inner').height() + 30 }, 600, function() { - opacity('theme-selector-inner', 0, 100, 750); + if ( !aclDisableTransitionFX ) + opacity('theme-selector-inner', 0, 100, 750); }); $('#theme-selector-inner li a').click(function() @@ -795,7 +798,8 @@ $('#theme-selector-inner').css('height', $('#theme-selector-inner').height()).fadeOut(600, function() { var div = document.createElement('div'); - domObjChangeOpac(0, div); + if ( !aclDisableTransitionFX ) + domObjChangeOpac(0, div); $(div).attr('id', 'theme-selector-style-list').append('

'); $('h3', div).text($lang.get('ajax_thmsel_lbl_choosestyle')); @@ -807,12 +811,14 @@ $(div).append('
' + $lang.get('etc_cancel') + '
'); - changeOpac(0, 'theme-selector-style-list'); + if ( !aclDisableTransitionFX ) + changeOpac(0, 'theme-selector-style-list'); $(this).html(div).show(); $('#theme-selector-body').animate({width: 300, height: $('#theme-selector-style-list').height() + 30}, 300, function() { - opacity('theme-selector-style-list', 0, 100, 500); + if ( !aclDisableTransitionFX ) + opacity('theme-selector-style-list', 0, 100, 500); }); $('.stylebtn').click(function() @@ -867,6 +873,18 @@ window.ajaxChangeThemeShowSuccess = function() { + if ( aclDisableTransitionFX ) + { + $('#theme-selector-inner').empty(); + } + else + { + setTimeout(function() + { + $('#theme-selector-inner').empty(); + }, 10); + } + $('#theme-selector-body').animate({width: 400, height: 300 }, 600, function() { $('#theme-selector-inner').append(' '); @@ -875,10 +893,6 @@ $('#theme-selector-inner').append('
' + $lang.get('ajax_thmsel_btn_close') + '
' + $lang.get('ajax_thmsel_btn_close_hint') + '
'); $('#theme-selector-inner').fadeIn(); }); - setTimeout(function() - { - $('#theme-selector-inner').empty(); - }, 10); } window.ajaxChangeStyleClose = function() @@ -890,8 +904,9 @@ { $(this).remove(); }); - }, 300); - opacity('theme-selector-inner', 100, 0, 250); + }, ( aclDisableTransitionFX ? 0 : 300)); + if ( !aclDisableTransitionFX ) + opacity('theme-selector-inner', 100, 0, 250); } function themeid_to_title(id) diff -r 35db370104ab -r 7e933a5c860b includes/clientside/static/enano-lib-basic.js --- a/includes/clientside/static/enano-lib-basic.js Sat Apr 04 22:16:30 2009 -0400 +++ b/includes/clientside/static/enano-lib-basic.js Sat Apr 04 22:17:32 2009 -0400 @@ -312,6 +312,9 @@ if ( onload_complete ) onload_hooks = new Array(); eval_global(ajax.responseText); + if ( window.jQuery && aclDisableTransitionFX ) + if ( window.jQuery.fx ) + window.jQuery.fx.off = true; load_hide_win(); if ( onload_complete ) runOnloadHooks();