|
@@ -63,6 +63,7 @@ export default class mainScene extends SGraphyScene {
|
|
this.addAllItemList(data);
|
|
this.addAllItemList(data);
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+
|
|
// 以下是绘制方法
|
|
// 以下是绘制方法
|
|
|
|
|
|
/**
|
|
/**
|
|
@@ -133,22 +134,22 @@ export default class mainScene extends SGraphyScene {
|
|
});
|
|
});
|
|
}
|
|
}
|
|
// 按下
|
|
// 按下
|
|
- mouseDown(_this: any, fn: any){
|
|
|
|
|
|
+ mouseDown(_this: any, fn: any) {
|
|
this.root.children.forEach(item => {
|
|
this.root.children.forEach(item => {
|
|
item.connect("mouseDown", _this, fn);
|
|
item.connect("mouseDown", _this, fn);
|
|
});
|
|
});
|
|
- }
|
|
|
|
|
|
+ }
|
|
//移动
|
|
//移动
|
|
- mouseMove(_this: any, fn: any){
|
|
|
|
|
|
+ mouseMove(_this: any, fn: any) {
|
|
this.root.children.forEach(item => {
|
|
this.root.children.forEach(item => {
|
|
item.connect("mouseMove", _this, fn);
|
|
item.connect("mouseMove", _this, fn);
|
|
});
|
|
});
|
|
- }
|
|
|
|
|
|
+ }
|
|
// 点解结束
|
|
// 点解结束
|
|
- mouseUp(_this: any, fn: any){
|
|
|
|
|
|
+ mouseUp(_this: any, fn: any) {
|
|
this.root.children.forEach(item => {
|
|
this.root.children.forEach(item => {
|
|
item.connect("mouseUp", _this, fn);
|
|
item.connect("mouseUp", _this, fn);
|
|
});
|
|
});
|
|
- }
|
|
|
|
|
|
+ }
|
|
|
|
|
|
}
|
|
}
|