equal
deleted
inserted
replaced
21 namespace gui { |
21 namespace gui { |
22 |
22 |
23 /*virtual*/ void TextButton::OnPaint(EvtPaint &ev) |
23 /*virtual*/ void TextButton::OnPaint(EvtPaint &ev) |
24 { |
24 { |
25 DrawBackground(ev); |
25 DrawBackground(ev); |
26 Point center = CenterPt(); |
26 Point center = Size() / 2; |
27 if (m_pushed) center += Point(1, 1); |
27 if (m_pushed) center += Point(1, 1); |
28 DrawStringCentered(center.x, center.y - 5, m_text, 0); |
28 DrawStringCentered(center.x, center.y - 5, m_text, 0); |
29 ev.SetHandled(); |
29 ev.SetHandled(); |
30 } |
30 } |
31 |
31 |