32 lines
902 B
TypeScript
32 lines
902 B
TypeScript
import { Container, FederatedPointerEvent, Point } from 'pixi.js';
|
|
import { IGraphicScene } from '../app';
|
|
import { JlGraphic } from '../core';
|
|
import { KeyListener } from './KeyboardPlugin';
|
|
interface GraphicControler {
|
|
controlerList: KeyListener[];
|
|
check: () => boolean;
|
|
}
|
|
/**
|
|
* 图形复制插件
|
|
*/
|
|
export declare class GraphicCopyPlugin {
|
|
container: Container;
|
|
scene: IGraphicScene;
|
|
keyListeners: KeyListener[];
|
|
graphicControlers: GraphicControler[];
|
|
copys: JlGraphic[];
|
|
start?: Point;
|
|
running: boolean;
|
|
moveLimit?: 'x' | 'y';
|
|
constructor(scene: IGraphicScene);
|
|
updateMoveLimit(limit?: 'x' | 'y'): void;
|
|
init(): void;
|
|
addGraphicControlers(graphicControlers: GraphicControler[]): void;
|
|
clear(): void;
|
|
onPointerMove(e: FederatedPointerEvent): void;
|
|
onFinish(): void;
|
|
saveCopyGraphic(): void;
|
|
cancle(): void;
|
|
}
|
|
export {};
|