diff options
| author | 2022-12-17 10:19:18 -0500 | |
|---|---|---|
| committer | 2022-12-17 10:41:20 -0500 | |
| commit | 45672d43e3a88b735dffab36e4e503b76055e59d (patch) | |
| tree | 55e609fd46935e37c2221a8c76937eed106981b4 | |
| parent | Merge pull request #6354 from ogniK5377/device-name (diff) | |
| download | yuzu-45672d43e3a88b735dffab36e4e503b76055e59d.tar.gz yuzu-45672d43e3a88b735dffab36e4e503b76055e59d.tar.xz yuzu-45672d43e3a88b735dffab36e4e503b76055e59d.zip | |
qt: avoid setting WA_DontCreateNativeAncestors on all platforms
Diffstat (limited to '')
| -rw-r--r-- | src/yuzu/bootmanager.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/yuzu/bootmanager.cpp b/src/yuzu/bootmanager.cpp index 642f96690..7147c6aaa 100644 --- a/src/yuzu/bootmanager.cpp +++ b/src/yuzu/bootmanager.cpp | |||
| @@ -44,6 +44,8 @@ | |||
| 44 | #include "yuzu/bootmanager.h" | 44 | #include "yuzu/bootmanager.h" |
| 45 | #include "yuzu/main.h" | 45 | #include "yuzu/main.h" |
| 46 | 46 | ||
| 47 | static Core::Frontend::WindowSystemType GetWindowSystemType(); | ||
| 48 | |||
| 47 | EmuThread::EmuThread(Core::System& system_) : system{system_} {} | 49 | EmuThread::EmuThread(Core::System& system_) : system{system_} {} |
| 48 | 50 | ||
| 49 | EmuThread::~EmuThread() = default; | 51 | EmuThread::~EmuThread() = default; |
| @@ -228,8 +230,10 @@ class RenderWidget : public QWidget { | |||
| 228 | public: | 230 | public: |
| 229 | explicit RenderWidget(GRenderWindow* parent) : QWidget(parent), render_window(parent) { | 231 | explicit RenderWidget(GRenderWindow* parent) : QWidget(parent), render_window(parent) { |
| 230 | setAttribute(Qt::WA_NativeWindow); | 232 | setAttribute(Qt::WA_NativeWindow); |
| 231 | setAttribute(Qt::WA_DontCreateNativeAncestors); | ||
| 232 | setAttribute(Qt::WA_PaintOnScreen); | 233 | setAttribute(Qt::WA_PaintOnScreen); |
| 234 | if (GetWindowSystemType() == Core::Frontend::WindowSystemType::Wayland) { | ||
| 235 | setAttribute(Qt::WA_DontCreateNativeAncestors); | ||
| 236 | } | ||
| 233 | } | 237 | } |
| 234 | 238 | ||
| 235 | virtual ~RenderWidget() = default; | 239 | virtual ~RenderWidget() = default; |