mirror of https://github.com/BOINC/boinc.git
MGR: fix text position in progress bars
svn path=/trunk/boinc/; revision=16148
This commit is contained in:
parent
4ed28dab7a
commit
7b53ee40f1
|
@ -314,10 +314,14 @@ void CBOINCListCtrl::DrawProgressBars()
|
|||
#endif
|
||||
r.x = x;
|
||||
r.width = w;
|
||||
r.Inflate(-1, -2);
|
||||
rr = r;
|
||||
|
||||
wxString progressString = m_pParentView->GetProgressText(row);
|
||||
dc.GetTextExtent(progressString, &xx, &yy);
|
||||
|
||||
r.y += (r.height - yy - 1) / 2;
|
||||
|
||||
// Adapted from ellipis code in wxRendererGeneric::DrawHeaderButtonContents()
|
||||
if (xx > r.width) {
|
||||
int ellipsisWidth;
|
||||
|
@ -334,9 +338,6 @@ void CBOINCListCtrl::DrawProgressBars()
|
|||
xx += ellipsisWidth;
|
||||
}
|
||||
}
|
||||
|
||||
rr = r;
|
||||
rr.Inflate(-1, -2);
|
||||
|
||||
dc.SetLogicalFunction(wxCOPY);
|
||||
dc.SetBackgroundMode(wxSOLID);
|
||||
|
|
Loading…
Reference in New Issue