source: trunk/web-app/js/jsUtil.js @ 322

Last change on this file since 322 was 322, checked in by gav, 14 years ago

Move JavascriptService to JsUtilService.
Consolidate similar JsUtilService methods.
Create JsUtilTagLib?.
Disable pulsing of asset tree loading image.

File size: 418 bytes
Line 
1
2function toggleUtil(id) {
3    $(id).toggle();
4}
5
6function toggleWithImgUtil(id, imageId, openImgUrl, closedImgUrl) {
7
8    $(id).toggle();
9
10    if( $(id).visible() ) {
11        $(imageId).src= openImgUrl;
12    }
13    else {
14        $(imageId).src= closedImgUrl;
15    }
16}
17
18function showUtil(id) {
19    Effect.Appear(id,{duration:0.4,queue:'end'});
20}
21
22function hideUtil(id) {
23    Effect.Fade(id,{duration:0.4,queue:'end'});
24}
Note: See TracBrowser for help on using the repository browser.