mirror of
https://github.com/ZuneDev/ZuneShell.dll.git
synced 2026-07-27 13:11:51 -07:00
Removed unnecessary casts
This commit is contained in:
@@ -58,7 +58,7 @@ namespace Microsoft.Iris.Layout
|
||||
areasOfInterestList.Add(interest);
|
||||
}
|
||||
|
||||
public override string ToString() => InvariantString.Format("AreaOfInterest(\"{0}\", {1}, {2})", (object)this.Id, (object)this.Rectangle, (object)this.DisplayRectangle);
|
||||
public override string ToString() => InvariantString.Format("AreaOfInterest(\"{0}\", {1}, {2})", Id, Rectangle, DisplayRectangle);
|
||||
|
||||
public override int GetHashCode() => this._rectangle.GetHashCode() ^ this._displayRectangle.GetHashCode() ^ this._id.GetHashCode();
|
||||
|
||||
|
||||
@@ -37,6 +37,6 @@ namespace Microsoft.Iris.Layout
|
||||
|
||||
public static DataCookie Data => AreaOfInterestLayoutInput.s_dataProperty;
|
||||
|
||||
public override string ToString() => InvariantString.Format("{0}({1})", (object)this.GetType().Name, (object)this._id);
|
||||
public override string ToString() => InvariantString.Format("{0}({1})", this.GetType().Name, _id);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -17,7 +17,7 @@ namespace Microsoft.Iris.Layout
|
||||
public LayoutNodeEnumerator(ILayoutNode start)
|
||||
{
|
||||
this._start = start;
|
||||
this._current = (ILayoutNode)null;
|
||||
this._current = null;
|
||||
this._haventStartedYet = true;
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ namespace Microsoft.Iris.Layout
|
||||
|
||||
public void Reset()
|
||||
{
|
||||
this._current = (ILayoutNode)null;
|
||||
this._current = null;
|
||||
this._haventStartedYet = true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -87,15 +87,15 @@ namespace Microsoft.Iris.Layout
|
||||
stringBuilder.Append(this.GetType().Name);
|
||||
stringBuilder.Append("(");
|
||||
stringBuilder.Append("Bounds=");
|
||||
stringBuilder.Append((object)this._bounds);
|
||||
stringBuilder.Append(_bounds);
|
||||
stringBuilder.Append(", Offset=");
|
||||
stringBuilder.Append((object)this._offset);
|
||||
stringBuilder.Append(_offset);
|
||||
stringBuilder.Append(", View=");
|
||||
stringBuilder.Append((object)this._viewBounds);
|
||||
stringBuilder.Append(_viewBounds);
|
||||
if (this._peripheralViewBounds != this._viewBounds)
|
||||
{
|
||||
stringBuilder.Append(", Peripheral=");
|
||||
stringBuilder.Append((object)this._peripheralViewBounds);
|
||||
stringBuilder.Append(_peripheralViewBounds);
|
||||
}
|
||||
stringBuilder.Append(")");
|
||||
return stringBuilder.ToString();
|
||||
|
||||
@@ -120,7 +120,7 @@ namespace Microsoft.Iris.Layout
|
||||
Size size2 = constraint;
|
||||
Size size3 = size1;
|
||||
Size size4 = minSize;
|
||||
if ((policy & SharedSizePolicy.SharesWidth) != (SharedSizePolicy)0)
|
||||
if ((policy & SharedSizePolicy.SharesWidth) != 0)
|
||||
{
|
||||
if (!this._accumulatingSize)
|
||||
{
|
||||
@@ -143,7 +143,7 @@ namespace Microsoft.Iris.Layout
|
||||
size4.Width = Math.Max(size3.Width, size4.Width);
|
||||
}
|
||||
}
|
||||
if ((policy & SharedSizePolicy.SharesHeight) != (SharedSizePolicy)0)
|
||||
if ((policy & SharedSizePolicy.SharesHeight) != 0)
|
||||
{
|
||||
if (!this._accumulatingSize)
|
||||
{
|
||||
@@ -175,9 +175,9 @@ namespace Microsoft.Iris.Layout
|
||||
if (!this._accumulatingSize)
|
||||
return;
|
||||
Size size1 = this.Size;
|
||||
if ((policy & SharedSizePolicy.ContributesToWidth) != (SharedSizePolicy)0 && size.Width > size1.Width)
|
||||
if ((policy & SharedSizePolicy.ContributesToWidth) != 0 && size.Width > size1.Width)
|
||||
size1.Width = size.Width;
|
||||
if ((policy & SharedSizePolicy.ContributesToHeight) != (SharedSizePolicy)0 && size.Height > size1.Height)
|
||||
if ((policy & SharedSizePolicy.ContributesToHeight) != 0 && size.Height > size1.Height)
|
||||
size1.Height = size.Height;
|
||||
this.SetSize(size1, false);
|
||||
this.EnsureApplySize();
|
||||
@@ -213,7 +213,7 @@ namespace Microsoft.Iris.Layout
|
||||
{
|
||||
SharedSizePolicy sharedSizePolicy = dependent.SharedSizePolicy;
|
||||
Size size2 = ((ILayoutNode)dependent).DesiredSize - dependent.Margins.Size;
|
||||
if (size1.Width != size2.Width && (sharedSizePolicy & SharedSizePolicy.SharesWidth) != (SharedSizePolicy)0 || size1.Height != size2.Height && (sharedSizePolicy & SharedSizePolicy.SharesHeight) != (SharedSizePolicy)0)
|
||||
if (size1.Width != size2.Width && (sharedSizePolicy & SharedSizePolicy.SharesWidth) != 0 || size1.Height != size2.Height && (sharedSizePolicy & SharedSizePolicy.SharesHeight) != 0)
|
||||
dependent.MarkLayoutInvalid();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user