mirror of
https://github.com/konvajs/konva.git
synced 2026-01-23 21:34:50 +08:00
Spline no longer extends Line. Blob no longer extends Spline. point getter setters were extracted out to Node. control point expansion method in Spline was pulled out and put in Util
This commit is contained in:
@@ -58,6 +58,8 @@ Test.Modules.BLOB = {
|
||||
test(blob2.getTension() === 1.2, 'blob2 tension should be 1.2');
|
||||
|
||||
test(blob1.getClassName() === 'Blob', 'getClassName should be Blob');
|
||||
|
||||
//console.log(blob1.getPoints())
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
Test.Modules.LINE = {
|
||||
'*add line': function(containerId) {
|
||||
'add line': function(containerId) {
|
||||
var stage = new Kinetic.Stage({
|
||||
container: containerId,
|
||||
width: 578,
|
||||
@@ -84,7 +84,7 @@ Test.Modules.LINE = {
|
||||
test(redLine.getPoints()[0].x === 4, 'redLine points is wrong');
|
||||
|
||||
},
|
||||
'*add dashed line': function(containerId) {
|
||||
'add dashed line': function(containerId) {
|
||||
var stage = new Kinetic.Stage({
|
||||
container: containerId,
|
||||
width: 578,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
Test.Modules.POLYGON = {
|
||||
'*add polygon': function(containerId) {
|
||||
'add polygon': function(containerId) {
|
||||
var stage = new Kinetic.Stage({
|
||||
container: containerId,
|
||||
width: 578,
|
||||
|
||||
@@ -69,15 +69,9 @@ Test.Modules.SPLINE = {
|
||||
layer.add(line3);
|
||||
stage.add(layer);
|
||||
|
||||
/*
|
||||
line.transitionTo({
|
||||
spline: 3,
|
||||
duration: 3
|
||||
});
|
||||
*/
|
||||
|
||||
test(line1.getClassName() === 'Spline', 'getClassName should be Spline');
|
||||
|
||||
|
||||
},
|
||||
'create from points represented as a flat array': function(containerId) {
|
||||
var stage = new Kinetic.Stage({
|
||||
|
||||
Reference in New Issue
Block a user