aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2011-05-10 11:11:33 -0400
committerScott González <scott.gonzalez@gmail.com>2011-05-10 11:11:33 -0400
commit7e239e2ab2c1147c4a14f6de36e7ecbbdf3d97e9 (patch)
treec82244b86061d08320bf887d15a9af20b03aabbd
parentb546f316bedcb74c507378b1460ed5c87d44e213 (diff)
parentd4bdd19429b82acebf37772669b796cc84e1674a (diff)
downloadjquery-ui-7e239e2ab2c1147c4a14f6de36e7ecbbdf3d97e9.tar.gz
jquery-ui-7e239e2ab2c1147c4a14f6de36e7ecbbdf3d97e9.zip
Merge remote branch 'gnarf37/effects-visual-test'
-rw-r--r--tests/visual/effects.all.html12
-rw-r--r--tests/visual/effects.all.js20
2 files changed, 27 insertions, 5 deletions
diff --git a/tests/visual/effects.all.html b/tests/visual/effects.all.html
index 1fc35f700..fed35de8a 100644
--- a/tests/visual/effects.all.html
+++ b/tests/visual/effects.all.html
@@ -146,6 +146,18 @@
</li>
<li>
+ <div class="effect" id="size">
+ <p>Size Default Show/Hide</p>
+ </div>
+ </li>
+
+ <li>
+ <div class="effect" id="sizeToggle">
+ <p>Size Toggle</p>
+ </div>
+ </li>
+
+ <li>
<div class="effect" id="slideDown">
<p>Slide down</p>
</div>
diff --git a/tests/visual/effects.all.js b/tests/visual/effects.all.js
index 9cf7487c9..a28c41a89 100644
--- a/tests/visual/effects.all.js
+++ b/tests/visual/effects.all.js
@@ -30,10 +30,10 @@ $(function() {
var el = $(this);
el.addClass("current").hide(duration, function() {
setTimeout(function() {
- el.show(duration, function() { el.removeClass("current") });
+ el.show(duration, function() { el.removeClass("current"); });
}, wait);
- })
- })
+ });
+ });
effect("#blindLeft", "blind", { direction: "left" });
effect("#blindUp", "blind", { direction: "up" });
@@ -63,6 +63,16 @@ $(function() {
effect("#puff", "puff", { times: 2 });
effect("#scale", "scale", {});
+ effect("#size", "size", {});
+ $("#sizeToggle").bind("click", function() {
+ var opts = { to: { width: 300, height: 300 }};
+ $(this).addClass('current')
+ .toggle("size", opts, duration)
+ .delay(wait)
+ .toggle("size", opts, duration, function() {
+ $(this).removeClass("current");
+ });
+ });
$("#shake").bind("click", function() { $(this).addClass("current").effect("shake", {}, 100, function() { $(this).removeClass("current"); }); });
@@ -84,13 +94,13 @@ $(function() {
$("#removeClass").click(function() {
$(this).addClass("current").removeClass(function() {
window.console && console.log(arguments);
- return "current"
+ return "current";
}, duration);
});
$("#toggleClass").click(function() {
$(this).toggleClass(function() {
window.console && console.log(arguments);
- return "current"
+ return "current";
}, duration);
});
});