Check ComboBoxRenderer.IsSupported
This commit is contained in:
parent
9f1b47bcfd
commit
80b684e95b
1 changed files with 2 additions and 2 deletions
|
@ -126,7 +126,7 @@ internal sealed class CustomTreeView : TreeView
|
||||||
TextRenderer.DrawText(graphics, text, font, point, color, TextFormatFlags.Default);
|
TextRenderer.DrawText(graphics, text, font, point, color, TextFormatFlags.Default);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (form is SelectForm)
|
if (form is SelectForm && ComboBoxRenderer.IsSupported)
|
||||||
{
|
{
|
||||||
Selection selection = Selection.FromId(platform, id);
|
Selection selection = Selection.FromId(platform, id);
|
||||||
if (selection is not null && selection.CanUseProxy)
|
if (selection is not null && selection.CanUseProxy)
|
||||||
|
@ -209,7 +209,7 @@ internal sealed class CustomTreeView : TreeView
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (e.Button is not MouseButtons.Left)
|
if (e.Button is not MouseButtons.Left || !ComboBoxRenderer.IsSupported)
|
||||||
return;
|
return;
|
||||||
if (comboBoxBounds.Count > 0 && selectForm is not null)
|
if (comboBoxBounds.Count > 0 && selectForm is not null)
|
||||||
foreach (KeyValuePair<Selection, Rectangle> pair in comboBoxBounds)
|
foreach (KeyValuePair<Selection, Rectangle> pair in comboBoxBounds)
|
||||||
|
|
Loading…
Reference in a new issue