| | |
| | | Assert.Equal(LayoutManager.MinHeight, result.Value.Bounds.Height); |
| | | Assert.Equal(LayoutManager.MaxScale, result.Value.Scale); |
| | | Assert.Equal(LayoutManager.MinOpacity, result.Value.Opacity); |
| | | Assert.Equal(DisplayLayer.AppTop, manager.Update(layout.InstanceId, new WidgetLayoutPatch { DisplayLayer = DisplayLayer.AppTop }).Value?.DisplayLayer); |
| | | Assert.True(result.Value.Bounds.Right >= monitor.WorkArea.X + LayoutManager.MinVisibleDip); |
| | | Assert.True(result.Value.Bounds.Bottom >= monitor.WorkArea.Y + LayoutManager.MinVisibleDip); |
| | | } |
| | |
| | | } |
| | | |
| | | [Fact] |
| | | public async Task Update_AllowsUnlockingLockedWidget() |
| | | { |
| | | var (manager, monitor, _) = await CreateLoadedManagerAsync(); |
| | | var plugin = CreatePlugin(locked: true); |
| | | var layout = manager.CreateFromPlugin(plugin, monitor.Id); |
| | | |
| | | var result = manager.Update(layout.InstanceId, new WidgetLayoutPatch { IsLocked = false }); |
| | | |
| | | Assert.True(result.Succeeded); |
| | | Assert.False(result.Value?.IsLocked); |
| | | } |
| | | |
| | | [Fact] |
| | | public async Task ReconcileMonitors_MovesMissingSecondaryMonitorToPrimary() |
| | | { |
| | | var (manager, _, diagnostics) = await CreateLoadedManagerAsync(); |