* 修正UIDataGridView放在TabControl上主题切换问题

This commit is contained in:
Sunny 2021-01-26 23:04:35 +08:00
parent 15f36ad374
commit 5f29ccdc84
6 changed files with 17 additions and 17 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -474,23 +474,23 @@ namespace Sunny.UI
} }
} }
protected override void OnGridColorChanged(EventArgs e) // protected override void OnGridColorChanged(EventArgs e)
{ // {
base.OnGridColorChanged(e); // base.OnGridColorChanged(e);
_style = UIStyle.Custom; // _style = UIStyle.Custom;
} // }
//
protected override void OnDefaultCellStyleChanged(EventArgs e) // protected override void OnDefaultCellStyleChanged(EventArgs e)
{ // {
base.OnDefaultCellStyleChanged(e); // base.OnDefaultCellStyleChanged(e);
_style = UIStyle.Custom; // _style = UIStyle.Custom;
} // }
//
protected override void OnColumnDefaultCellStyleChanged(DataGridViewColumnEventArgs e) // protected override void OnColumnDefaultCellStyleChanged(DataGridViewColumnEventArgs e)
{ // {
base.OnColumnDefaultCellStyleChanged(e); // base.OnColumnDefaultCellStyleChanged(e);
_style = UIStyle.Custom; // _style = UIStyle.Custom;
} // }
public DataGridViewColumn AddColumn(string columnName, string dataPropertyName, int fillWeight = 100, DataGridViewContentAlignment alignment = DataGridViewContentAlignment.MiddleCenter, bool readOnly = true) public DataGridViewColumn AddColumn(string columnName, string dataPropertyName, int fillWeight = 100, DataGridViewContentAlignment alignment = DataGridViewContentAlignment.MiddleCenter, bool readOnly = true)
{ {