@mescius/dsimageviewer
Version:
Document Solutions Image Viewer
34 lines (33 loc) • 1.73 kB
TypeScript
import { PointLocation } from "../../../../ImageViewer/Models/SelectionBoxTypes";
import { PaintToolbar } from "./../../PaintToolbar";
import { SelectedRegion } from "./SelectedRegion";
import { InternalFilterName } from "./../InternalFilters";
import { SelectedRegionState, SelectionToolType } from "./types";
export declare class SelectedRegionsDispatcher {
context: PaintToolbar;
_selectedRegion: SelectedRegion | null;
_copiedRegionState?: SelectedRegionState;
constructor(context: PaintToolbar);
get hasDirtyRegions(): boolean;
get hasSelectedRegions(): boolean;
get hasUnclosedRegion(): boolean;
applyRegionFilter(name: InternalFilterName, intencityValue1?: number, intencityValue2?: number, replaceSameFilter?: boolean): Promise<boolean>;
selectAll(): void;
execCopy(): boolean;
copyImage(copiedImage?: HTMLCanvasElement): void;
execDelete(): Promise<boolean>;
execPaste(destPoint: PointLocation): Promise<void>;
isLastAppliedFilter(name: InternalFilterName): boolean;
updateSelectedRegion(s: SelectedRegionState, skipUndo?: boolean): void;
cancelChanges(): boolean;
commitSelectedRegion(resetCopiedImage?: boolean): void;
clearRegionsSelection(commit?: boolean): void;
ensureSelectedRegion(selectionToolType: SelectionToolType, owner: PaintToolbar): void;
finishSelectedRegion(force?: boolean): boolean;
getSelectedClipPaths(relativeToBounds?: boolean): Path2D[];
hasRegionWithType(t: SelectionToolType): boolean | null;
invalidate(): void;
onPointerStart(point: PointLocation): void;
onPointerMove(point: PointLocation): void;
onPointerEnd(point: PointLocation): boolean | undefined;
}