1 write to _viewport
aspire-tray (1)
src\Aspire.Tray\Common\TrayPanel.cs (1)
830_viewport = new(0, HeaderHeight + noticeHeight, Width, Math.Max(0, height - chrome));
33 references to _viewport
aspire-tray (33)
src\Aspire.Tray\Common\TrayPanel.cs (33)
139return _viewport; 398_scroll = Math.Clamp(before - deltaY, 0, Math.Max(0, _contentHeight - _viewport.Height)); 509if (bottom > _viewport.Bottom) 511_scroll += Math.Min(bottom - _viewport.Bottom, Math.Max(0, top - _viewport.Y)); 548if (bottom > _viewport.Bottom) 550_scroll += bottom - _viewport.Bottom; 552if (top < _viewport.Y) 554_scroll -= _viewport.Y - top; 627else if (target.Bounds.Y < _viewport.Y) 629_scroll -= _viewport.Y - target.Bounds.Y; 631else if (target.Bounds.Bottom > _viewport.Bottom) 633_scroll += target.Bounds.Bottom - _viewport.Bottom; 831_scroll = Math.Clamp(_scroll, 0, Math.Max(0, _contentHeight - _viewport.Height)); 832var listOrigin = _viewport.Y - _scroll; 862commands.Add(new FillPathCommand(PanelPath.Rectangle(new(0, _viewport.Y, Width, 1)), palette.Separator)); 867commands.Add(new PushClipCommand(_viewport)); 874var sink = top + item.Height <= _viewport.Y || top >= _viewport.Bottom ? hidden : commands; 910if (_contentHeight > _viewport.Height && _viewport.Height > 0) 912var thumb = Math.Max(24, _viewport.Height * _viewport.Height / _contentHeight); 913var travel = _viewport.Height - thumb - 8; 914var thumbY = _viewport.Y + 4 + travel * _scroll / (_contentHeight - _viewport.Height); 933var clip = IsChrome(focused.Kind) ? panel : _viewport; 963if (_viewport.Y > HeaderHeight) 966Line(HeaderHeight + 8 + 17, "notice", new(0, HeaderHeight, Width, _viewport.Y - HeaderHeight)); 989if (top + item.Height <= _viewport.Y || top >= _viewport.Bottom) 1515var hit = IsChrome(key.Kind) ? bounds : bounds.Intersect(_viewport); 1531_accessible.Add(new(PanelAccessibleKey.For(label), PanelAccessibleRole.Text, text, bounds, chrome ? bounds : bounds.Intersect(_viewport)));