Skip to content

Commit

Permalink
Merge branch 'dev' of github.com:ChineseDron/Tangram-component into dev
Browse files Browse the repository at this point in the history
  • Loading branch information
ChineseDron committed Dec 31, 2011
2 parents 7948636 + b721cf0 commit 204941b
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions test/baidu/fx/mask.js
Expand Up @@ -11,7 +11,7 @@ test('dom', function() {
$(t).css('position', 'absolute');
baidu.fx.mask(t, {
onafterfinish : function() {
equals(this._className, 'baidu.fx.mask', 'after finish');
equals(this.__type, 'baidu.fx.mask', 'after finish');
start();
}
});
Expand All @@ -27,7 +27,7 @@ test('id', function() {
$(t).css('position', 'absolute');
h = baidu.fx.mask(t, {
onafterfinish : function() {
equals(this._className, 'baidu.fx.mask');
equals(this.__type, 'baidu.fx.mask');
start();
}
});
Expand Down
2 changes: 1 addition & 1 deletion test/baidu/ui/Calendar.js
Expand Up @@ -217,7 +217,7 @@ module('baidu.ui.Calendar');
var g = function(id, child) {
var _id = '';
if (id.charAt(0) == '#')
_id = '#' + ui.getId(id.substr(1));
_id = '#' + ui.getId(id.substr(1)).replace("$", "\\$");
else if (id.charAt(0) == '.')
_id = '.' + ui.getClass(id.substr(1));
child && (_id += ' ' + child);
Expand Down
8 changes: 4 additions & 4 deletions test/baidu/ui/Menubar/Menubar$fx.js
Expand Up @@ -25,7 +25,7 @@ test('Open a common Menubar(fadeIn) '
+ 'a custom onafterfinish function');
var len = baidu.fx.current(menu.getBody()).length;
equal(
baidu.fx.current(menu.getBody())[len - 1]['_className'],
baidu.fx.current(menu.getBody())[len - 1]['__type'],
'baidu.fx.fadeIn', 'The menubar fadeIn');
menu.close();
}
Expand All @@ -40,7 +40,7 @@ test('Open a common Menubar(fadeIn) '
+ 'a custom onafterfinish function');
var len = baidu.fx.current(menu.getBody()).length;
equal(
baidu.fx.current(menu.getBody())[len - 1]['_className'],
baidu.fx.current(menu.getBody())[len - 1]['__type'],
'baidu.fx.fadeOut', 'The menubar fadeOut');
start();
}
Expand Down Expand Up @@ -72,7 +72,7 @@ test('Open a common Menubar(expand) and'
showFxOptions : {
onafterfinish : function() {
var len = baidu.fx.current(menu.getBody()).length;
var fx = baidu.fx.current(menu.getBody())[len - 1]['_className'];
var fx = baidu.fx.current(menu.getBody())[len - 1]['__type'];
var guid = baidu.fx.current(menu.getBody())[len - 1]['guid'];
ok(fx == 'baidu.fx.expand_collapse',
'The menubar expand');
Expand All @@ -82,7 +82,7 @@ test('Open a common Menubar(expand) and'
hideFxOptions : {
onafterfinish : function() {
var len = baidu.fx.current(menu.getBody()).length;
var fx = baidu.fx.current(menu.getBody())[len - 1]['_className'];
var fx = baidu.fx.current(menu.getBody())[len - 1]['__type'];
var guid = baidu.fx.current(menu.getBody())[len - 1]['guid'];
ok((fx == 'baidu.fx.expand_collapse')
&& guid != baidu.fx
Expand Down
8 changes: 4 additions & 4 deletions test/baidu/ui/Tooltip/Tooltip$fx.js
Expand Up @@ -14,15 +14,15 @@ test('Open a common tooltip(fadeIn) and '
showFxOptions : {
onafterfinish : function() {
var len = baidu.fx.current(tp.getMain()).length;
equal(baidu.fx.current(tp.getMain())[len-1]['_className'],
equal(baidu.fx.current(tp.getMain())[len-1]['__type'],
'baidu.fx.fadeIn', 'The tooltip fadeIn');
tp.close();
}
},
hideFxOptions : {
onafterfinish : function() {
var len = baidu.fx.current(tp.getMain()).length;
equal(baidu.fx.current(tp.getMain())[len-1]['_className'],
equal(baidu.fx.current(tp.getMain())[len-1]['__type'],
'baidu.fx.fadeOut', 'The tooltip fadeOut');
start();
}
Expand Down Expand Up @@ -52,7 +52,7 @@ test('Open a common tooltip(expand) and '
onafterfinish : function() {
var len = baidu.fx.current(tp.getMain()).length;
var len = baidu.fx.current(tp.getMain()).length;
var fx = baidu.fx.current(tp.getMain())[len-1]['_className'];
var fx = baidu.fx.current(tp.getMain())[len-1]['__type'];
var guid = baidu.fx.current(tp.getMain())[len-1]['guid'];
ok(fx == 'baidu.fx.expand_collapse', 'The tooltip expand');
tp.close();
Expand All @@ -61,7 +61,7 @@ test('Open a common tooltip(expand) and '
hideFxOptions : {
onafterfinish : function() {
var len = baidu.fx.current(tp.getMain()).length;
var fx = baidu.fx.current(tp.getMain())[len-1]['_className'];
var fx = baidu.fx.current(tp.getMain())[len-1]['__type'];
var guid = baidu.fx.current(tp.getMain())[len-1]['guid'];
ok((fx == 'baidu.fx.expand_collapse') &&
guid != baidu.fx.current(tp.getMain())[len-1]['_guid'],
Expand Down
2 changes: 1 addition & 1 deletion test/baidu/ui/Tree.js
Expand Up @@ -147,7 +147,7 @@ test('TreeNode constructor', function() {
});
equals(node.uiType, 'tree-node', 'check ui type');
equals(node.type, 'leaf', 'check node type');
ok(/TANGRAM__[a-z]+/.test(node.id), 'check node id : ' + node.id);
ok(/TANGRAM\$\d+/.test(node.id), 'check node id : ' + node.id);
});

test('TreeNode function appendData', function() {
Expand Down

0 comments on commit 204941b

Please sign in to comment.