mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
Use the main window as the parent to all user cards on macOS (#2185)
This commit is contained in:
parent
540870f9fe
commit
53c96097c9
2 changed files with 9 additions and 2 deletions
|
@ -29,7 +29,7 @@
|
||||||
- Minor: Improve UX of the "Login expired!" message (#2029)
|
- Minor: Improve UX of the "Login expired!" message (#2029)
|
||||||
- Minor: PageUp and PageDown now scroll in the selected split (#2070, #2081)
|
- Minor: PageUp and PageDown now scroll in the selected split (#2070, #2081)
|
||||||
- Minor: Allow highlights to be excluded from `/mentions`. Excluded highlights will not trigger tab highlights either. (#1793, #2036)
|
- Minor: Allow highlights to be excluded from `/mentions`. Excluded highlights will not trigger tab highlights either. (#1793, #2036)
|
||||||
- Minor: Flag all popup dialogs as actual dialogs so they get the relevant window manager hints (#1843, #2182)
|
- Minor: Flag all popup dialogs as actual dialogs so they get the relevant window manager hints (#1843, #2182, #2185)
|
||||||
- Minor: Don't show update button for nightly builds on macOS and Linux, this was already the case for Windows (#2163, #2164)
|
- Minor: Don't show update button for nightly builds on macOS and Linux, this was already the case for Windows (#2163, #2164)
|
||||||
- Bugfix: Fix crash occurring when pressing Escape in the Color Picker Dialog (#1843)
|
- Bugfix: Fix crash occurring when pressing Escape in the Color Picker Dialog (#1843)
|
||||||
- Bugfix: Fix bug preventing users from setting the highlight color of the second entry in the "User" highlights tab (#1898)
|
- Bugfix: Fix bug preventing users from setting the highlight color of the second entry in the "User" highlights tab (#1898)
|
||||||
|
|
|
@ -39,6 +39,7 @@
|
||||||
#include "util/Twitch.hpp"
|
#include "util/Twitch.hpp"
|
||||||
#include "widgets/Scrollbar.hpp"
|
#include "widgets/Scrollbar.hpp"
|
||||||
#include "widgets/TooltipWidget.hpp"
|
#include "widgets/TooltipWidget.hpp"
|
||||||
|
#include "widgets/Window.hpp"
|
||||||
#include "widgets/dialogs/SettingsDialog.hpp"
|
#include "widgets/dialogs/SettingsDialog.hpp"
|
||||||
#include "widgets/dialogs/UserInfoPopup.hpp"
|
#include "widgets/dialogs/UserInfoPopup.hpp"
|
||||||
#include "widgets/helper/EffectLabel.hpp"
|
#include "widgets/helper/EffectLabel.hpp"
|
||||||
|
@ -1965,8 +1966,14 @@ void ChannelView::hideEvent(QHideEvent *)
|
||||||
|
|
||||||
void ChannelView::showUserInfoPopup(const QString &userName)
|
void ChannelView::showUserInfoPopup(const QString &userName)
|
||||||
{
|
{
|
||||||
|
QWidget *userCardParent = this;
|
||||||
|
#ifdef Q_OS_MACOS
|
||||||
|
// Order of closing/opening/killing widgets when the "Automatically close user info popups" setting is enabled is special on macOS, so user info popups should always use the main window as its parent
|
||||||
|
userCardParent =
|
||||||
|
static_cast<QWidget *>(&(getApp()->windows->getMainWindow()));
|
||||||
|
#endif
|
||||||
auto *userPopup =
|
auto *userPopup =
|
||||||
new UserInfoPopup(getSettings()->autoCloseUserPopup, this);
|
new UserInfoPopup(getSettings()->autoCloseUserPopup, userCardParent);
|
||||||
userPopup->setData(userName, this->hasSourceChannel()
|
userPopup->setData(userName, this->hasSourceChannel()
|
||||||
? this->sourceChannel_
|
? this->sourceChannel_
|
||||||
: this->underlyingChannel_);
|
: this->underlyingChannel_);
|
||||||
|
|
Loading…
Reference in a new issue