[development] jQuery animation help?

Steve Ringwood nevets at mailbag.com
Mon Jul 30 04:32:13 UTC 2007


Morbus

	Here is where I would start

	Visit http://interface.eyecon.ro/, in left hand column under DOWNLOAD
	click 'Interface 1.2',zip file contains both compressed and uncompressed
source.

	You want ifxscle.js (uncompressed version)

	A suggested way to start, incomplete though since it does not deal with the
	way restore is handled.  (It actually restores the shrink case, it just
hides the content)

	Two approaches
		Add new function like Grow and Shrink
			Advantage:  Keeps existing functionality
			Drawback:  Need to add to type to scale and zoom code

		Modify Shrink function
			Advantage:  Not sure of any
			Drawback:  Need to a least modify zoom code so it does
					not set display to none

		In both case key is call to scale function, here is the shrink version
			jQuery.fx.Scale(this, speed, 100, 1, true, callback, 'shrink', easing);
				100 is starting size (as percent)
				1 is ending size (as percent)

				Could try changing 1 to say 30.

				Also need to at least change this in z.zoom

			if (z.type == 'shrink' || z.type == 'puff'){
				z.el.css('display', 'none');
				if (z.type == 'puff') {
					if (window.ActiveXObject)
						z.el.get(0).style.filter = "alpha(opacity=" + 100 + ")";
					z.el.get(0).style.opacity = 1;
				}
			}else
				z.el.css('display', 'block');

				so if is only for type 'puff'

Steve Ringwood
Nevets Software





More information about the development mailing list