* UIRoundProcess:修改显示值
This commit is contained in:
parent
79bced975f
commit
7f0b93c40a
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -74,7 +74,6 @@ namespace Sunny.UI
|
|||||||
set
|
set
|
||||||
{
|
{
|
||||||
inner = Math.Max(value, 0);
|
inner = Math.Max(value, 0);
|
||||||
inner = Math.Min(value, outer - 5);
|
|
||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -88,7 +87,6 @@ namespace Sunny.UI
|
|||||||
set
|
set
|
||||||
{
|
{
|
||||||
outer = Math.Max(value, 5);
|
outer = Math.Max(value, 5);
|
||||||
inner = Math.Min(inner, outer - 5);
|
|
||||||
Invalidate();
|
Invalidate();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -152,6 +150,16 @@ namespace Sunny.UI
|
|||||||
|
|
||||||
protected override void OnPaintFill(Graphics g, GraphicsPath path)
|
protected override void OnPaintFill(Graphics g, GraphicsPath path)
|
||||||
{
|
{
|
||||||
|
int iin = Math.Min(inner, outer);
|
||||||
|
int iou = Math.Max(inner, outer);
|
||||||
|
if (iin == iou)
|
||||||
|
{
|
||||||
|
iou = iin + 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
inner = iin;
|
||||||
|
outer = iou;
|
||||||
|
|
||||||
g.FillFan(ProcessBackColor, ClientRectangle.Center(), Inner, Outer, 0, 360);
|
g.FillFan(ProcessBackColor, ClientRectangle.Center(), Inner, Outer, 0, 360);
|
||||||
g.FillFan(ProcessColor, ClientRectangle.Center(), Inner, Outer, -90, Value * 1.0f / Maximum * 360.0f);
|
g.FillFan(ProcessColor, ClientRectangle.Center(), Inner, Outer, -90, Value * 1.0f / Maximum * 360.0f);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user