mirror of
https://github.com/gui-cs/Terminal.Gui.git
synced 2025-12-28 16:58:01 +01:00
Backed out some changes and fixed unit tests
This commit is contained in:
@@ -66,7 +66,7 @@ public partial class View
|
||||
{
|
||||
if (_frame == value)
|
||||
{
|
||||
return;
|
||||
//return;
|
||||
}
|
||||
|
||||
_frame = value with { Width = Math.Max (value.Width, 0), Height = Math.Max (value.Height, 0) };
|
||||
@@ -169,7 +169,7 @@ public partial class View
|
||||
|
||||
if (Equals (_x, value))
|
||||
{
|
||||
return;
|
||||
//return;
|
||||
}
|
||||
OnResizeNeeded ();
|
||||
}
|
||||
@@ -205,7 +205,7 @@ public partial class View
|
||||
{
|
||||
if (Equals (_y, value))
|
||||
{
|
||||
return;
|
||||
//return;
|
||||
}
|
||||
|
||||
_y = value ?? throw new ArgumentNullException (nameof (value), @$"{nameof (Y)} cannot be null");
|
||||
@@ -243,7 +243,7 @@ public partial class View
|
||||
{
|
||||
if (Equals (_height, value))
|
||||
{
|
||||
return;
|
||||
//return;
|
||||
}
|
||||
|
||||
_height = value ?? throw new ArgumentNullException (nameof (value), @$"{nameof (Height)} cannot be null");
|
||||
@@ -298,7 +298,7 @@ public partial class View
|
||||
{
|
||||
if (Equals (_width, value))
|
||||
{
|
||||
return;
|
||||
// return;
|
||||
}
|
||||
|
||||
_width = value ?? throw new ArgumentNullException (nameof (value), @$"{nameof (Width)} cannot be null");
|
||||
|
||||
@@ -550,7 +550,8 @@ public class ToScreenTests (ITestOutputHelper output)
|
||||
View view = new ()
|
||||
{
|
||||
Width = 10,
|
||||
Height = 10
|
||||
Height = 10,
|
||||
ScrollSettings = ScrollSettings.NoRestrict
|
||||
};
|
||||
|
||||
Rectangle testRect = new Rectangle (0, 0, 1, 1);
|
||||
|
||||
@@ -160,7 +160,8 @@ public class ViewportTests (ITestOutputHelper output)
|
||||
View view = new ()
|
||||
{
|
||||
Width = 10,
|
||||
Height = 10
|
||||
Height = 10,
|
||||
ScrollSettings = ScrollSettings.NoRestrict
|
||||
};
|
||||
|
||||
Assert.Equal (new Rectangle (0, 0, 10, 10), view.Frame);
|
||||
|
||||
Reference in New Issue
Block a user