passthrow autosize to parent form
This commit is contained in:
@@ -68,17 +68,32 @@ public partial class RadFlyoutBase : UserControl
|
|||||||
// SVG Symbols
|
// SVG Symbols
|
||||||
radButton_Cancel.SvgImage = CancelSvg;
|
radButton_Cancel.SvgImage = CancelSvg;
|
||||||
radButton_Confirm.SvgImage = ConfirmSvg;
|
radButton_Confirm.SvgImage = ConfirmSvg;
|
||||||
|
|
||||||
|
// Hide bars in Designer
|
||||||
|
//if (DesignMode)
|
||||||
|
//{
|
||||||
|
// tableLayoutPanel_ActionPanel.Visible = false;
|
||||||
|
// tableLayoutPanel_TitlePanel.Visible = false;
|
||||||
|
//}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void FlyoutDialogBase_ParentChanged(object? sender, EventArgs e)
|
private void FlyoutDialogBase_ParentChanged(object? sender, EventArgs e)
|
||||||
{
|
{
|
||||||
var frm = FindForm();
|
var frm = FindForm();
|
||||||
|
|
||||||
if (frm != null)
|
if (frm != null)
|
||||||
{
|
{
|
||||||
if (RegisterDialogAccept)
|
if (RegisterDialogAccept)
|
||||||
frm.AcceptButton = radButton_Confirm;
|
frm.AcceptButton = radButton_Confirm;
|
||||||
|
|
||||||
if (RegisterDialogCancel)
|
if (RegisterDialogCancel)
|
||||||
frm.CancelButton = radButton_Cancel;
|
frm.CancelButton = radButton_Cancel;
|
||||||
|
|
||||||
|
if (AutoSize)
|
||||||
|
{
|
||||||
|
frm.AutoSize = true;
|
||||||
|
frm.AutoSizeMode = AutoSizeMode.GrowAndShrink;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user