UNPKG

ole

Version:

OpenLayers Editor

68 lines (67 loc) 1.6 kB
export default RotateControl; /** * Tool with for rotating geometries. * @extends {Control} * @alias ole.RotateControl */ declare class RotateControl extends Control { /** * @inheritdoc * @param {Object} [options] Control options. * @param {string} [options.rotateAttribute] Name of a feature attribute * that is used for storing the rotation in rad. * @param {ol.style.Style.StyleLike} [options.style] Style used for the rotation layer. */ constructor(options?: { rotateAttribute?: string | undefined; style?: any; } | undefined); /** * @type {ol.interaction.Pointer} * @private */ private pointerInteraction; /** * @type {string} * @private */ private rotateAttribute; /** * Layer for rotation feature. * @type {ol.layer.Vector} * @private */ private rotateLayer; /** * Handle a pointer down event. * @param {ol.MapBrowserEvent} event Down event * @private */ private onDown; dragging: boolean | undefined; feature: any; initialRotation: any; /** * Handle a pointer drag event. * @param {ol.MapBrowserEvent} event Down event * @private */ private onDrag; /** * Handle a pointer up event. * @param {ol.MapBrowserEvent} event Down event * @private */ private onUp; rotateFeature: any; center: any; /** * @inheritdoc */ activate(): void; /** * @inheritdoc */ deactivate(silent: any): void; } import Control from './control';