[Settings] Custom color format UI tweaks (#22790)

* Custom color format tweaks

* Delete vs. remove

* Update expect.txt

* [ColorPicker]Support BGR and RGB decimal value formats (#22771)

* ColorPicker add both decimal value formats

* ColorPicker, custom format dialog, resizing columns

* Custom color format tweaks

* Delete vs. remove

* Update expect.txt

* Fix rebase

* Fix error
This commit is contained in:
Niels Laute
2022-12-16 11:15:55 +01:00
committed by GitHub
parent b17955c968
commit b775d0710f
9 changed files with 382 additions and 305 deletions

View File

@@ -395,7 +395,7 @@ namespace Microsoft.PowerToys.Settings.UI.ViewModels
return newColorFormatModel;
}
internal void SetValidity(ColorFormatModel colorFormatModel, string oldName)
internal bool SetValidity(ColorFormatModel colorFormatModel, string oldName)
{
if ((colorFormatModel.Format == string.Empty) || (colorFormatModel.Name == string.Empty))
{
@@ -410,6 +410,8 @@ namespace Microsoft.PowerToys.Settings.UI.ViewModels
colorFormatModel.IsValid = ColorFormats.Count(x => x.Name.ToUpperInvariant().Equals(colorFormatModel.Name.ToUpperInvariant(), StringComparison.Ordinal))
< (colorFormatModel.IsNew ? 1 : 2);
}
return colorFormatModel.IsValid;
}
internal void DeleteModel(ColorFormatModel colorFormatModel)