mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Fix volume icon over video.
This commit is contained in:
parent
412cfb24d2
commit
4c23d51be5
2 changed files with 8 additions and 5 deletions
|
@ -633,6 +633,8 @@ int MembersRow::statusIconHeight() const {
|
||||||
|
|
||||||
void MembersRow::paintStatusIcon(
|
void MembersRow::paintStatusIcon(
|
||||||
Painter &p,
|
Painter &p,
|
||||||
|
int x,
|
||||||
|
int y,
|
||||||
const style::PeerListItem &st,
|
const style::PeerListItem &st,
|
||||||
const style::font &font,
|
const style::font &font,
|
||||||
bool selected) {
|
bool selected) {
|
||||||
|
@ -652,8 +654,7 @@ void MembersRow::paintStatusIcon(
|
||||||
p.setPen(color);
|
p.setPen(color);
|
||||||
|
|
||||||
const auto speakerRect = QRect(
|
const auto speakerRect = QRect(
|
||||||
st.statusPosition
|
QPoint(x, y + (font->height - statusIconHeight()) / 2),
|
||||||
+ QPoint(0, (font->height - statusIconHeight()) / 2),
|
|
||||||
_statusIcon->speaker.size());
|
_statusIcon->speaker.size());
|
||||||
const auto arcPosition = speakerRect.topLeft()
|
const auto arcPosition = speakerRect.topLeft()
|
||||||
+ QPoint(
|
+ QPoint(
|
||||||
|
@ -683,8 +684,8 @@ void MembersRow::paintStatusIcon(
|
||||||
p.setFont(st::normalFont);
|
p.setFont(st::normalFont);
|
||||||
p.setPen(st.statusFgActive);
|
p.setPen(st.statusFgActive);
|
||||||
p.drawTextLeft(
|
p.drawTextLeft(
|
||||||
st.statusPosition.x() + speakerRect.width() + _statusIcon->arcsWidth,
|
x + speakerRect.width() + _statusIcon->arcsWidth,
|
||||||
st.statusPosition.y(),
|
y,
|
||||||
fullWidth,
|
fullWidth,
|
||||||
_statusIcon->percent);
|
_statusIcon->percent);
|
||||||
p.restore();
|
p.restore();
|
||||||
|
@ -737,7 +738,7 @@ void MembersRow::paintComplexStatusText(
|
||||||
if (about.isEmpty()
|
if (about.isEmpty()
|
||||||
&& _state != State::Invited
|
&& _state != State::Invited
|
||||||
&& _state != State::MutedByMe) {
|
&& _state != State::MutedByMe) {
|
||||||
paintStatusIcon(p, st, font, selected);
|
paintStatusIcon(p, x, y, st, font, selected);
|
||||||
|
|
||||||
const auto translatedWidth = statusIconWidth();
|
const auto translatedWidth = statusIconWidth();
|
||||||
p.translate(translatedWidth, 0);
|
p.translate(translatedWidth, 0);
|
||||||
|
|
|
@ -178,6 +178,8 @@ private:
|
||||||
int statusIconHeight() const;
|
int statusIconHeight() const;
|
||||||
void paintStatusIcon(
|
void paintStatusIcon(
|
||||||
Painter &p,
|
Painter &p,
|
||||||
|
int x,
|
||||||
|
int y,
|
||||||
const style::PeerListItem &st,
|
const style::PeerListItem &st,
|
||||||
const style::font &font,
|
const style::font &font,
|
||||||
bool selected);
|
bool selected);
|
||||||
|
|
Loading…
Add table
Reference in a new issue