Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ViewportService

Manages the view state

Hierarchy

  • ViewportService

Index

Constructors

constructor

Properties

Private _currentViewport

_currentViewport: Viewport

Private _currentViewportJSON

_currentViewportJSON: string

Private _presentationMode

_presentationMode: PresentationMode = PresentationMode.PAGE

autoPublishEmbeddedViewport

autoPublishEmbeddedViewport: boolean = true

Automatically watch and publish the viewport during PresentationMode.EMBEDDED

changeEvent

changeEvent: Event<void> = new Event<void>()

An event that is raised when the viewport has changed

Private contextService

contextService: ContextService

element

element: HTMLDivElement

An HTMLDivElement which represents the viewport. This value is undefined in non-DOM environments.

Private focusService

focusService: FocusService

presentationModeChangeEvent

presentationModeChangeEvent: Event<PresentationMode> = new Event<PresentationMode>()

An event that is raised when the presentation mode has changed

rootElement

rootElement: HTMLDivElement

The root HTMLDivElement element for this view. This value is undefined in non-DOM environments.

Private sessionService

sessionService: SessionService

uiEvent

uiEvent: Event<object> = new Event<{event:UIEvent|MouseEvent|TouchEvent|PointerEvent|WheelEvent, forwardEvent:()=>void}>()

UI events that occur within this view. To handle an event (and prevent it from being forwarded to another layer) call event.stopImmediatePropagation().

Accessors

current

  • Get the current viewport

    Returns Viewport

presentationMode

  • The current presentation mode

    Returns PresentationMode

Methods

Private _updatePresentationMode

Private _updateViewport

  • _updateViewport(viewport: Viewport): void
  • Parameters

    Returns void

Private _watchEmbeddedViewport

  • _watchEmbeddedViewport(): void
  • Returns void

publishEmbeddedViewport

  • publishEmbeddedViewport(viewport?: Viewport): void
  • Publish the viewport being used in [[PresentationMode.EMBEDDED]] so that other apps can use the same viewport

    Parameters

    Returns void

requestPresentationMode

sendUIEventToSession

  • sendUIEventToSession(uievent: UIEvent, session?: SessionPort): void
  • Parameters

    Returns void

Generated using TypeDoc