Closed GoogleCodeExporter closed 9 years ago
Hi Kristof,
As I said in issue 63, there is a bug in slide* methods.
In waiting the fix in GQuery, implement the slideToogle by this way :
public void slideToogle(String selector, int millisec) {
final GQuery query = $(selector);
if ("none".equals(query.css("display"))) {
String height = "" + query.data("initialHeight") + "px";
query.as(Effects).animate("height: '" + height + "'", millisec,
new Function() {
@Override
public void f() {
query.show().height(null);
}
});
} else {
query.data("initialHeight", GQUtils.cur(query.get(0), "height", true));
query.as(Effects).animate("height: '0px'", millisec, new Function() {
@Override
public void f() {
query.hide();
}
});
}
}
...
slideToogle("#foo", 2000);
Julien
Original comment by julien.d...@gmail.com
on 5 Jan 2011 at 9:52
Original comment by julien.d...@gmail.com
on 15 Jan 2011 at 6:42
Original comment by julien.d...@gmail.com
on 15 Jan 2011 at 6:43
[deleted comment]
fixed in r330 Use last snapshot
Thanks for the reporting
Original comment by julien.d...@gmail.com
on 21 Jan 2011 at 3:42
Original issue reported on code.google.com by
kristof....@gmail.com
on 5 Nov 2010 at 12:51