when node is at the edge of the canvas, and you mouse over the node and then off the canvas, the mouseout handlers for the node are executed

This commit is contained in:
Eric Rowell
2012-04-01 11:34:22 -07:00
parent 86a1337017
commit bdafb3eb25
4 changed files with 36 additions and 1 deletions

View File

@@ -992,6 +992,31 @@ Test.prototype.tests = {
layer.add(group);
stage.add(layer);
},
'EVENTS - shape mouseout handlers when mouse leaves stage': function(containerId) {
var stage = new Kinetic.Stage({
container: containerId,
width: 578,
height: 200
});
var layer = new Kinetic.Layer();
var redCircle = new Kinetic.Circle({
x: 550,
y: stage.height / 2,
radius: 80,
strokeWidth: 4,
fill: 'red',
stroke: 'black',
name: 'circle'
});
redCircle.on('mouseout', function() {
log('mouseout');
});
layer.add(redCircle);
stage.add(layer);
},
'DRAG AND DROP - isDragging': function(containerId) {
var stage = new Kinetic.Stage({
container: containerId,