UNPKG

@kieler/klighd-core

Version:

Core KLighD diagram visualization with Sprotty

38 lines 1.81 kB
import { ActionHandlerRegistry, IActionHandler, IActionHandlerInitializer, ICommand, MouseListener, SModelElementImpl, SetUIExtensionVisibilityAction } from 'sprotty'; import { Action } from 'sprotty-protocol'; import { ProxyView } from './proxy-view'; /** * Wrapper action around {@link SetUIExtensionVisibilityAction} which shows the proxy. * Otherwise the proxy-view would be invisible. */ export type ShowProxyViewAction = SetUIExtensionVisibilityAction; export declare namespace ShowProxyViewAction { function create(): ShowProxyViewAction; } /** An action containing the {@link ProxyView}. */ export interface SendProxyViewAction extends Action { kind: typeof SendProxyViewAction.KIND; proxyView: ProxyView; } export declare namespace SendProxyViewAction { const KIND = "sendProxyViewAction"; function create(proxyView: ProxyView): SendProxyViewAction; } /** Handles all actions and mouse events regarding the {@link ProxyView}. */ export declare class ProxyViewActionHandler extends MouseListener implements IActionHandler, IActionHandlerInitializer { /** The proxy-view. */ private proxyView; private synthesesRegistry; private renderOptionsRegistry; private optionsRegistry; /** Whether the proxy-view was registered in the registries' onchange() method. Prevents registering multiple times. */ private onChangeRegistered; mouseMoved: boolean; mouseDown(_target: SModelElementImpl, event: MouseEvent): (Action | Promise<Action>)[]; mouseMove(): (Action | Promise<Action>)[]; mouseUp(target: SModelElementImpl, event: MouseEvent): (Action | Promise<Action>)[]; init(): void; handle(action: Action): void | Action | ICommand; initialize(registry: ActionHandlerRegistry): void; } //# sourceMappingURL=proxy-view-actions.d.ts.map