Home

# Class goog.positioning.AnchoredViewportPosition

Encapsulates a popup position where the popup is anchored at a corner of an element. The corners are swapped if dictated by the viewport. For instance if a popup is anchored with its top left corner to the bottom left corner of the anchor the popup is either displayed below the anchor (as specified) or above it if there's not enough room to display it below. When using this positioning object it's recommended that the movable element be absolutely positioned.

extends goog.positioning.AnchoredPosition

Instance Method Summary
| `correctCorner_(number status, ?goog.positioning.Corner corner) ⇒ ?goog.positioning.Corner` Flip the given corner if X or Y positioning failed.
| `getLastResortOverflow() ⇒ number`
| `reposition(?Element movableElement, ?goog.positioning.Corner movableCorner, ?goog.math.Box= opt_margin, ?goog.math.Size= opt_preferredSize)` Repositions the movable element.
| `setLastResortOverflow(number lastResortOverflow)`