@univerjsuiindexclassesContextmenuservice

@univerjs/ui v0.5.0-beta.1Docs


Class: ContextMenuService

Extends

Implements

Constructors

new ContextMenuService()

new ContextMenuService(): ContextMenuService

Returns

ContextMenuService

Inherited from

Disposable.constructor

Properties

PropertyModifierTypeDefault valueInherited fromDefined in
_disposedprotectedbooleanfalseDisposable._disposedsubmodules/univer/packages/core/src/shared/lifecycle.ts:93
disabledpublicbooleanfalse-submodules/univer/packages/ui/src/services/contextmenu/contextmenu.service.ts:46

Accessors

visible

Get Signature

get visible(): boolean
Returns

boolean

Implementation of

IContextMenuService.visible

Defined in

submodules/univer/packages/ui/src/services/contextmenu/contextmenu.service.ts:48

Methods

disable()

disable(): void

Returns

void

Implementation of

IContextMenuService.disable

Defined in

submodules/univer/packages/ui/src/services/contextmenu/contextmenu.service.ts:52


dispose()

dispose(): void

Returns

void

Inherited from

Disposable.dispose

Defined in

submodules/univer/packages/core/src/shared/lifecycle.ts:106


disposeWithMe()

disposeWithMe(disposable): IDisposable

Parameters

ParameterType
disposableDisposableLike

Returns

IDisposable

Inherited from

Disposable.disposeWithMe

Defined in

submodules/univer/packages/core/src/shared/lifecycle.ts:96


enable()

enable(): void

Returns

void

Implementation of

IContextMenuService.enable

Defined in

submodules/univer/packages/ui/src/services/contextmenu/contextmenu.service.ts:56


ensureNotDisposed()

protected ensureNotDisposed(): void

Returns

void

Inherited from

Disposable.ensureNotDisposed

Defined in

submodules/univer/packages/core/src/shared/lifecycle.ts:100


hideContextMenu()

hideContextMenu(): void

Returns

void

Implementation of

IContextMenuService.hideContextMenu

Defined in

submodules/univer/packages/ui/src/services/contextmenu/contextmenu.service.ts:67


registerContextMenuHandler()

registerContextMenuHandler(handler): IDisposable

Parameters

ParameterType
handlerIContextMenuHandler

Returns

IDisposable

Implementation of

IContextMenuService.registerContextMenuHandler

Defined in

submodules/univer/packages/ui/src/services/contextmenu/contextmenu.service.ts:71


triggerContextMenu()

triggerContextMenu(event, menuType): void

Parameters

ParameterType
eventIMouseEvent | IPointerEvent
menuTypestring

Returns

void

Implementation of

IContextMenuService.triggerContextMenu

Defined in

submodules/univer/packages/ui/src/services/contextmenu/contextmenu.service.ts:60