Subversion Repositories Applications.papyrus

Rev

Rev 1422 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1318 alexandre_ 1
/*
2
	Copyright (c) 2004-2006, The Dojo Foundation
3
	All Rights Reserved.
4
 
5
	Licensed under the Academic Free License version 2.1 or above OR the
6
	modified BSD license. For more information on Dojo licensing, see:
7
 
8
		http://dojotoolkit.org/community/licensing.shtml
9
*/
10
 
1422 alexandre_ 11
 
12
 
1318 alexandre_ 13
dojo.provide("dojo.lfx.toggle");
14
dojo.require("dojo.lfx.*");
15
dojo.lfx.toggle.plain = {show:function (node, duration, easing, callback) {
16
	dojo.html.show(node);
17
	if (dojo.lang.isFunction(callback)) {
18
		callback();
19
	}
20
}, hide:function (node, duration, easing, callback) {
21
	dojo.html.hide(node);
22
	if (dojo.lang.isFunction(callback)) {
23
		callback();
24
	}
25
}};
26
dojo.lfx.toggle.fade = {show:function (node, duration, easing, callback) {
27
	dojo.lfx.fadeShow(node, duration, easing, callback).play();
28
}, hide:function (node, duration, easing, callback) {
29
	dojo.lfx.fadeHide(node, duration, easing, callback).play();
30
}};
31
dojo.lfx.toggle.wipe = {show:function (node, duration, easing, callback) {
32
	dojo.lfx.wipeIn(node, duration, easing, callback).play();
33
}, hide:function (node, duration, easing, callback) {
34
	dojo.lfx.wipeOut(node, duration, easing, callback).play();
35
}};
36
dojo.lfx.toggle.explode = {show:function (node, duration, easing, callback, explodeSrc) {
37
	dojo.lfx.explode(explodeSrc || {x:0, y:0, width:0, height:0}, node, duration, easing, callback).play();
38
}, hide:function (node, duration, easing, callback, explodeSrc) {
39
	dojo.lfx.implode(node, explodeSrc || {x:0, y:0, width:0, height:0}, duration, easing, callback).play();
40
}};
41