ResizeProvider

ResizeProvider

This provider (singleton) is used for uniform monitoring of window size changes.

Constructor

new ResizeProvider()

Source:

Extends

  • EventTarget

Members

updateOnlyOnWidthChanges :boolean

Description:
  • Update events are only fired if the window viewport width has changed.

Source:

Update events are only fired if the window viewport width has changed.

Type:
  • boolean

(private, non-null) viewportSize_ :Size

Description:
  • Size of the window viewport

Source:

Size of the window viewport

Type:
  • Size

Methods

getViewportSize() → (non-null) {Size}

Source:
Returns:
Type
Size

(private) handleResize_()

Source:

update(opt_alwaysBubbleEventopt)

Description:
  • Checks if the window viewport size has changed from the stored size and fires the EventType.UPDATE event if it has changed.

Source:
Parameters:
Name Type Attributes Default Description
opt_alwaysBubbleEvent boolean <optional>
false

Forces the update event to be sent even if no resize is detected for the window size.