ActualSize executes CalculatePosition
This commit is contained in:
parent
5d380112ac
commit
9e6b441169
|
@ -10,11 +10,7 @@ namespace CC_Functions.Commandline.TUI
|
|||
public class CenteredScreen : Screen
|
||||
{
|
||||
private bool _resizing;
|
||||
|
||||
/// <summary>
|
||||
/// The actual size of this control. The "Size" property is assigned automatically
|
||||
/// </summary>
|
||||
public Size ActualSize;
|
||||
private Size _actualSize;
|
||||
|
||||
/// <summary>
|
||||
/// The panel used for storing and rendering the actual controls
|
||||
|
@ -59,6 +55,22 @@ namespace CC_Functions.Commandline.TUI
|
|||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The actual size of this control. The "Size" property is assigned automatically
|
||||
/// </summary>
|
||||
public Size ActualSize
|
||||
{
|
||||
get => _actualSize;
|
||||
set
|
||||
{
|
||||
if (_actualSize != value)
|
||||
{
|
||||
_actualSize = value;
|
||||
CalculatePosition(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Calculates the Size variable, Title and ContentPanel position/size
|
||||
/// </summary>
|
||||
|
|
Reference in New Issue