mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
refactor(contentdialog): Refactor window activate event
This commit is contained in:
parent
e3d74117ca
commit
378d648591
|
@ -484,18 +484,18 @@ bool ContentDialog::event(QEvent* event)
|
||||||
updateTitle(activeChatroomWidget);
|
updateTitle(activeChatroomWidget);
|
||||||
|
|
||||||
Friend* frnd = activeChatroomWidget->getFriend();
|
Friend* frnd = activeChatroomWidget->getFriend();
|
||||||
|
Group* group = activeChatroomWidget->getGroup();
|
||||||
|
|
||||||
|
GenericChatroomWidget *widget = nullptr;
|
||||||
|
|
||||||
if (frnd)
|
if (frnd)
|
||||||
{
|
widget = frnd->getFriendWidget();
|
||||||
frnd->getFriendWidget()->resetEventFlags();
|
|
||||||
frnd->getFriendWidget()->updateStatusLight();
|
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
widget = group->getGroupWidget();
|
||||||
Group* g = activeChatroomWidget->getGroup();
|
|
||||||
g->getGroupWidget()->resetEventFlags();
|
widget->resetEventFlags();
|
||||||
g->getGroupWidget()->updateStatusLight();
|
widget->updateStatusLight();
|
||||||
}
|
|
||||||
Widget::getInstance()->resetIcon();
|
Widget::getInstance()->resetIcon();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user