1 write to _viewport
aspire-tray (1)
src\Aspire.Tray\Common\TrayPanel.cs (1)
935
_viewport
= new(0, HeaderHeight + noticeHeight, Width, Math.Max(0, height - chrome));
32 references to _viewport
aspire-tray (32)
src\Aspire.Tray\Common\TrayPanel.cs (32)
145
return
_viewport
;
392
SetScrollOffset(_scroll + (y < thumb.Y ? -
_viewport
.Height :
_viewport
.Height));
445
_scroll = Math.Clamp(scroll, 0, Math.Max(0, _contentHeight -
_viewport
.Height));
478
trackTop =
_viewport
.Y + ScrollbarInset;
479
trackHeight =
_viewport
.Height - 2 * ScrollbarInset;
480
scrollRange = _contentHeight -
_viewport
.Height;
488
var thumbHeight = Math.Min(trackHeight, Math.Max(ScrollbarMinimumThumbHeight, trackHeight *
_viewport
.Height / _contentHeight));
592
if (bottom >
_viewport
.Bottom)
594
_scroll += Math.Min(bottom -
_viewport
.Bottom, Math.Max(0, top -
_viewport
.Y));
631
if (bottom >
_viewport
.Bottom)
633
_scroll += bottom -
_viewport
.Bottom;
635
if (top <
_viewport
.Y)
637
_scroll -=
_viewport
.Y - top;
710
else if (target.Bounds.Y <
_viewport
.Y)
712
_scroll -=
_viewport
.Y - target.Bounds.Y;
714
else if (target.Bounds.Bottom >
_viewport
.Bottom)
716
_scroll += target.Bounds.Bottom -
_viewport
.Bottom;
936
_scroll = Math.Clamp(_scroll, 0, Math.Max(0, _contentHeight -
_viewport
.Height));
937
var listOrigin =
_viewport
.Y - _scroll;
968
commands.Add(new FillPathCommand(PanelPath.Rectangle(new(0,
_viewport
.Y, Width, 1)), palette.Separator));
973
commands.Add(new PushClipCommand(
_viewport
));
980
var sink = top + item.Height <=
_viewport
.Y || top >=
_viewport
.Bottom ? hidden : commands;
1036
var clip = IsChrome(focused.Kind) ? panel :
_viewport
;
1066
if (
_viewport
.Y > HeaderHeight)
1069
Line(HeaderHeight + 8 + 17, "notice", new(0, HeaderHeight, Width,
_viewport
.Y - HeaderHeight));
1092
if (top + item.Height <=
_viewport
.Y || top >=
_viewport
.Bottom)
1625
var hit = IsChrome(key.Kind) ? bounds : bounds.Intersect(
_viewport
);
1641
_accessible.Add(new(PanelAccessibleKey.For(label), PanelAccessibleRole.Text, text, bounds, chrome ? bounds : bounds.Intersect(
_viewport
)));