Skip to content

Commit d41b7b4

Browse files
committed
made new destroy methods return the API.
1 parent 66dc548 commit d41b7b4

File tree

9 files changed

+34
-12
lines changed

9 files changed

+34
-12
lines changed

build.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<project name="jQuery.Tools" default="min">
22

33
<taskdef resource="net/sf/antcontrib/antlib.xml"/>
4-
<property name="version" value="1.2.2"/>
4+
<property name="version" value="1.2.3"/>
55
<property name="build" value="build/${version}"/>
66
<property name="file" value="none"/>
77

src/tabs/tabs.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,7 @@
200200
destroy: function() {
201201
tabs.unbind(conf.event).removeClass(conf.current);
202202
panes.find("a[href^=#]").unbind("click.T");
203+
return self;
203204
}
204205

205206
});

src/validator/validator.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -348,12 +348,13 @@
348348
$(this).data("msg.el", null);
349349
}
350350
}).unbind(conf.errorInputEvent || '');
351+
return self;
351352
},
352353

353-
destroy: function() {
354-
self.reset();
354+
destroy: function() {
355355
form.unbind(conf.formEvent).unbind("reset.V");
356356
inputs.unbind(conf.inputEvent || '').unbind("change.V");
357+
return self.reset();
357358
},
358359

359360

test/overlay/index.htm

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,16 @@
1212
top: 'center',
1313
speed: 500,
1414

15+
mask: {
16+
color: '#fff',
17+
18+
// load mask a little faster
19+
loadSpeed: 200,
20+
21+
// very transparent
22+
opacity: 0.5
23+
},
24+
1525
// effect: 'apple',
1626

1727
onStart: function(e) {
@@ -52,6 +62,8 @@
5262
}
5363
});
5464

65+
66+
$("a.o1").data("overlay").load();
5567
});
5668
</script>
5769

test/overlay/style.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ div.overlay {
66
padding:10px;
77
}
88

9-
div.overlay div.close {
9+
div.overlay a.close {
1010
background-image:url(img/close.png);
1111
position:absolute;
1212
right:5px;

test/scrollable/index.html

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,12 @@
1818

1919
<script>
2020
$(function() {
21-
window.api = $(".scrollable").scrollable({ mousewheel: true})
21+
window.api = $(".scrollable").scrollable({ mousewheel: true, size: 5})
2222
.navigator({idPrefix: 'a', history: true}).data("scrollable");
23+
24+
api.onBeforeSeek(function() {
25+
// return false;
26+
});
2327
});
2428
</script>
2529

test/tabs/index.html

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11

2-
<script src="../jquery-1.3.2.js"></script>
2+
<script src="../js/jquery-1.4.2.js"></script>
33
<script src="../../src/tabs/tabs.js"></script>
4-
<script src="../../src/tabs/tabs.history.js"></script>
54
<link rel="stylesheet" type="text/css" href="tabs.css"/>
65

76
<!-- tabs -->

test/toolbox/mask/mask.htm

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11

2-
<script src="../../js/jquery-1.3.2.js"></script>
3-
<script src="../toolbox.mask.js"></script>
2+
<script src="../../js/jquery-1.4.2.js"></script>
3+
<script src="../../../src/toolbox/toolbox.expose.js"></script>
44

55
<h1>Jotain tulee tähän</h1>
66

7-
<button onClick="$.mask.load({startOpacity: 0.5})">load mask</button>
7+
<button onClick="$.mask.load({startOpacity: 0.5, maskId: 'mask', color: null})">load mask</button>
88

99

10-
<div id="mask" style="background-color:blue"></div>
10+
<div style="width:800px;border:1px solid black; height:300px">lkjlkjlj</div>
11+
12+
<div id="mask" style="background-color:blue;"> sadfsadf</div>

test/validator/validator.htm

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
<!DOCTYPE html>
33
<script src="../js/jquery-1.4.1.min.js"></script>
44
<script src="../../src/validator/validator.js"></script>
5+
<script src="../../src/dateinput/dateinput.js"></script>
56

67
<style>
78
body {
@@ -48,7 +49,7 @@
4849
/>
4950
</p>
5051
<p>
51-
date <input type="date" title="Use format yyyy-mm-dd" name="day" />
52+
date <input type="date" title="Use format yyyy-mm-dd" name="day" min="-40" required="true" />
5253
</p>
5354

5455
<p>
@@ -90,6 +91,8 @@
9091

9192
}).data("validator");
9293

94+
$(":date").dateinput();
95+
9396
api.onFail(function() {
9497
console.info("FAIL", this, arguments);
9598
});

0 commit comments

Comments
 (0)