1
0
mirror of https://github.com/Artemis-RGB/Artemis synced 2025-12-13 05:48:35 +00:00
This commit is contained in:
Robert 2021-07-11 19:45:34 +02:00
parent 5b6fc9eec7
commit d10ffcf62a

View File

@ -261,8 +261,14 @@ namespace Artemis.UI.Screens.ProfileEditor.Visualization
public void ResetZoomAndPan()
{
if (!Devices.Any())
{
PanZoomViewModel.Reset();
return;
}
// Create a rect surrounding all devices
SKRect rect = new SKRect(
SKRect rect = new(
Devices.Min(d => d.Rectangle.Left),
Devices.Min(d => d.Rectangle.Top),
Devices.Max(d => d.Rectangle.Right),