Exemplo n.º 1
0
        /* Returns the ClientRect of the current origin. */
        public async Task <ClientRect> GetOriginRect(DnetOverlayInterop dnetOverlayInterop)
        {
            if (!string.IsNullOrEmpty(_originElementReference.Id))
            {
                _origin = await dnetOverlayInterop.GetBoundingClientRect(_originElementReference);
            }

            var originRect = new ClientRect
            {
                Top    = _origin.Top,
                Left   = _origin.Left,
                Right  = _origin.Left + _origin.Width,
                Bottom = _origin.Top + _origin.Height,
                Width  = _origin.Width,
                Height = _origin.Height
            };

            return(originRect);
        }
Exemplo n.º 2
0
 public FlexibleConnectedPositionStrategyBuilder FlexibleConnectedTo(FlexibleConnectedPositionStrategyOrigin origin)
 {
     _origin = origin;;
     return(this);
 }