Browse Source

Region formatting

pull/165/head
Ionite 1 year ago
parent
commit
f0b4654c73
No known key found for this signature in database
  1. 20
      StabilityMatrix.Avalonia/Controls/AdvancedImageBox.axaml.cs

20
StabilityMatrix.Avalonia/Controls/AdvancedImageBox.axaml.cs

@ -40,13 +40,6 @@ namespace StabilityMatrix.Avalonia.Controls;
[SuppressMessage("ReSharper", "MemberCanBePrivate.Global")] [SuppressMessage("ReSharper", "MemberCanBePrivate.Global")]
public class AdvancedImageBox : TemplatedControl public class AdvancedImageBox : TemplatedControl
{ {
private static readonly Rect EmptyRect = new();
private static bool IsRectEmpty(Rect rect)
{
return rect == EmptyRect;
}
#region Bindable Base #region Bindable Base
/// <summary> /// <summary>
/// Multicast event for property change notifications. /// Multicast event for property change notifications.
@ -1893,6 +1886,19 @@ public class AdvancedImageBox : TemplatedControl
#endregion #endregion
#region Utility methods #region Utility methods
/// <summary>
/// Determines whether the specified rectangle is empty
/// </summary>
private static bool IsRectEmpty(Rect rect)
{
return rect == EmptyRect;
}
/// <summary>
/// Static empty rectangle
/// </summary>
private static readonly Rect EmptyRect = new();
/// <summary> /// <summary>
/// Determines whether the specified point is located within the image view port /// Determines whether the specified point is located within the image view port
/// </summary> /// </summary>

Loading…
Cancel
Save