fix(地图遮罩): 修复小地图点渲染逻辑,增加对视口宽度为零的判断

This commit is contained in:
辉鸭蛋
2026-02-24 15:29:21 +08:00
parent c162d32f4d
commit cfb9e49fba

View File

@@ -155,7 +155,7 @@ public sealed class MiniMapPointsCanvas : FrameworkElement
private void RenderPoints()
{
using var dc = _drawingVisual.RenderOpen();
if (_allPoints.Count == 0 || _viewportRect.IsEmpty)
if (_allPoints.Count == 0 || _viewportRect.IsEmpty || _viewportRect.Width == 0)
{
return;
}