mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-03-01 03:50:43 +00:00
Improve polls layout.
This commit is contained in:
parent
4346aecb61
commit
d5bf742912
@ -963,11 +963,12 @@ void Poll::paintFilling(
|
|||||||
const auto &icon = (chosen && !correct)
|
const auto &icon = (chosen && !correct)
|
||||||
? st::historyPollChoiceWrong
|
? st::historyPollChoiceWrong
|
||||||
: st::historyPollChoiceRight;
|
: st::historyPollChoiceRight;
|
||||||
|
const auto cleft = aleft - st::historyPollPercentSkip - icon.width();
|
||||||
const auto ctop = ftop - (icon.height() - thickness) / 2;
|
const auto ctop = ftop - (icon.height() - thickness) / 2;
|
||||||
p.drawEllipse(aleft, ctop, icon.width(), icon.height());
|
p.drawEllipse(cleft, ctop, icon.width(), icon.height());
|
||||||
icon.paint(p, aleft, ctop, width);
|
icon.paint(p, cleft, ctop, width);
|
||||||
barleft += icon.width() - radius;
|
//barleft += icon.width() - radius;
|
||||||
barwidth -= icon.width() - radius;
|
//barwidth -= icon.width() - radius;
|
||||||
}
|
}
|
||||||
if (barwidth > 0) {
|
if (barwidth > 0) {
|
||||||
p.drawRoundedRect(barleft, ftop, barwidth, thickness, radius, radius);
|
p.drawRoundedRect(barleft, ftop, barwidth, thickness, radius, radius);
|
||||||
|
Loading…
Reference in New Issue
Block a user