mirror of
https://github.com/microsoft/PowerToys.git
synced 2026-04-05 18:57:19 +02:00
[DSC] Add support for ImageresizerSizes property (#32657)
Add support for ImageresizerSizes property - do not use ints for enums in ImageSize struct - add required converters - extend setAdditional functionality - add samples Co-authored-by: Andrey Nekrasov <1828123+yuyoyuppe@users.noreply.github.com>
This commit is contained in:
@@ -233,10 +233,10 @@ namespace ViewModelTests
|
||||
// Assert
|
||||
ImageSize newTestSize = viewModel.Sizes.First(x => x.Id == 0);
|
||||
Assert.AreEqual(newTestSize.Name, "New size 1");
|
||||
Assert.AreEqual(newTestSize.Fit, (int)ResizeFit.Fit);
|
||||
Assert.AreEqual(newTestSize.Fit, ResizeFit.Fit);
|
||||
Assert.AreEqual(newTestSize.Width, 854);
|
||||
Assert.AreEqual(newTestSize.Height, 480);
|
||||
Assert.AreEqual(newTestSize.Unit, (int)ResizeUnit.Pixel);
|
||||
Assert.AreEqual(newTestSize.Unit, ResizeUnit.Pixel);
|
||||
}
|
||||
|
||||
[TestMethod]
|
||||
@@ -287,10 +287,10 @@ namespace ViewModelTests
|
||||
{
|
||||
Id = 0,
|
||||
Name = "Test",
|
||||
Fit = (int)ResizeFit.Fit,
|
||||
Fit = ResizeFit.Fit,
|
||||
Width = 30,
|
||||
Height = 30,
|
||||
Unit = (int)ResizeUnit.Pixel,
|
||||
Unit = ResizeUnit.Pixel,
|
||||
};
|
||||
|
||||
double negativeWidth = -2.0;
|
||||
|
||||
Reference in New Issue
Block a user