This commit is contained in:
@@ -102,6 +102,22 @@ namespace Accentra.Controls
|
||||
private bool bHiding = false;
|
||||
private bool bCancel = true; // Determines whether to Cancel
|
||||
|
||||
// Added my Volian 4/27/11
|
||||
private int _MaxRows = -1;
|
||||
|
||||
public int MaxRows
|
||||
{
|
||||
get { return _MaxRows; }
|
||||
set { _MaxRows = value; }
|
||||
}
|
||||
private int _MaxCols = -1;
|
||||
|
||||
public int MaxCols
|
||||
{
|
||||
get { return _MaxCols; }
|
||||
set { _MaxCols = value; }
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Similar to <code><see cref="DialogResult"/>
|
||||
/// == <see cref="DialogResult.Cancel"/></code>,
|
||||
@@ -146,6 +162,9 @@ namespace Accentra.Controls
|
||||
if (SquareQX < 7) SquareQX = 7;
|
||||
if (SquareQY < 5) SquareQY = 5;
|
||||
|
||||
if (_MaxRows > 0 && SquareQY > _MaxRows) SquareQY = _MaxRows;
|
||||
if (_MaxCols > 0 && SquareQX > _MaxCols) SquareQX = _MaxCols;
|
||||
|
||||
// Second, expand the dimensions of this form according to the
|
||||
// number of visible squares.
|
||||
this.Width = (SquareX * (SquareQX)) + 5;
|
||||
|
Reference in New Issue
Block a user