mirror of
https://github.com/konvajs/konva.git
synced 2025-05-02 20:05:08 +08:00
updated global object utilities
This commit is contained in:
parent
5765ab749b
commit
ac3f512ab8
3
dist/kinetic-core.js
vendored
3
dist/kinetic-core.js
vendored
@ -159,7 +159,7 @@ Kinetic.GlobalObject = {
|
||||
}
|
||||
},
|
||||
/*
|
||||
* cherry-picked and modified utilities from underscore.js
|
||||
* cherry-picked utilities from underscore.js
|
||||
*/
|
||||
_isElement: function(obj) {
|
||||
return !!(obj && obj.nodeType == 1);
|
||||
@ -171,6 +171,7 @@ Kinetic.GlobalObject = {
|
||||
return Object.prototype.toString.call(obj) == '[object Array]';
|
||||
},
|
||||
_isObject: function(obj) {
|
||||
//return obj === Object(obj);
|
||||
return (obj !== undefined && obj.constructor == Object);
|
||||
},
|
||||
_isNumber: function(obj) {
|
||||
|
4
dist/kinetic-core.min.js
vendored
4
dist/kinetic-core.min.js
vendored
File diff suppressed because one or more lines are too long
@ -131,7 +131,7 @@ Kinetic.GlobalObject = {
|
||||
}
|
||||
},
|
||||
/*
|
||||
* cherry-picked and modified utilities from underscore.js
|
||||
* cherry-picked utilities from underscore.js
|
||||
*/
|
||||
_isElement: function(obj) {
|
||||
return !!(obj && obj.nodeType == 1);
|
||||
@ -143,6 +143,7 @@ Kinetic.GlobalObject = {
|
||||
return Object.prototype.toString.call(obj) == '[object Array]';
|
||||
},
|
||||
_isObject: function(obj) {
|
||||
//return obj === Object(obj);
|
||||
return (obj !== undefined && obj.constructor == Object);
|
||||
},
|
||||
_isNumber: function(obj) {
|
||||
|
@ -390,7 +390,7 @@ Test.prototype.tests = {
|
||||
layer.add(Ellipse);
|
||||
stage.add(layer);
|
||||
},
|
||||
'*EVENTS - move mouse from shape to another shape in same layer': function(containerId) {
|
||||
'EVENTS - move mouse from shape to another shape in same layer': function(containerId) {
|
||||
var stage = new Kinetic.Stage({
|
||||
container: containerId,
|
||||
width: 578,
|
||||
|
Loading…
Reference in New Issue
Block a user