public static string ModeToText(this SelectedStretchMode mode) { switch (mode) { case SelectedStretchMode.Fill: return("Fill"); case SelectedStretchMode.None: return("None"); case SelectedStretchMode.Uniform: return("Uniform"); case SelectedStretchMode.UniformToFill: return("UniformToFill"); default: throw new ArgumentException(@"Stretch mode is not recognized", nameof(mode)); } }
public SetStretchModeMessage(SelectedStretchMode selectedStretch) => SelectedStretch = selectedStretch;
public SelectedStretchModeMessage(SelectedStretchMode mode) => Mode = mode;