Removed Equal/GetHashCode from base classes

This commit is contained in:
Tig
2024-05-17 11:25:07 -04:00
parent c035426cd6
commit a89db3c5ab
2 changed files with 6 additions and 25 deletions

View File

@@ -278,6 +278,12 @@ public abstract class Dim
return Math.Max (GetAnchor (superviewContentSize - location), 0);
}
/// <summary>
/// Diagnostics API to determine if this Dim object references other views.
/// </summary>
/// <returns></returns>
internal virtual bool ReferencesOtherViews () { return false; }
#endregion virtual methods
#region operators
@@ -326,21 +332,6 @@ public abstract class Dim
#endregion operators
#region overrides
/// <summary>
/// Diagnostics API to determine if this Dim object references other views.
/// </summary>
/// <returns></returns>
internal virtual bool ReferencesOtherViews () { return false; }
/// <inheritdoc/>
public override bool Equals (object? other) { return other is Dim abs && abs == this; }
/// <inheritdoc/>
public override int GetHashCode () { return GetAnchor (0).GetHashCode (); }
#endregion overrides
}
/// <summary>

View File

@@ -385,16 +385,6 @@ public abstract class Pos
#endregion operators
#region overrides
/// <inheritdoc/>
public override bool Equals (object other) { return other is Pos abs && abs == this; }
/// <summary>Serves as the default hash function. </summary>
/// <returns>A hash code for the current object.</returns>
public override int GetHashCode () { return GetAnchor (0).GetHashCode (); }
#endregion overrides
}
/// <summary>