mirror of
https://git.eden-emu.dev/archive/citron
synced 2026-04-14 00:30:51 -04:00
fix(overhaul): UI and resolution bugs for Steam Deck (Gamescope)
Signed-off-by: Collecting <collecting@noreply.localhost>
This commit is contained in:
@@ -1,4 +1,5 @@
|
|||||||
// SPDX-FileCopyrightText: Copyright 2017 Citra Emulator Project
|
// SPDX-FileCopyrightText: Copyright 2017 Citra Emulator Project
|
||||||
|
// SPDX-FileCopyrightText: Copyright 2026 citron Emulator Project
|
||||||
// SPDX-License-Identifier: GPL-2.0-or-later
|
// SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
|
|
||||||
#include <QComboBox>
|
#include <QComboBox>
|
||||||
@@ -24,10 +25,17 @@
|
|||||||
enum class ConnectionType : u8 { TraversalServer, IP };
|
enum class ConnectionType : u8 { TraversalServer, IP };
|
||||||
|
|
||||||
DirectConnectWindow::DirectConnectWindow(Core::System& system_, QWidget* parent)
|
DirectConnectWindow::DirectConnectWindow(Core::System& system_, QWidget* parent)
|
||||||
: QDialog(parent, Qt::WindowTitleHint | Qt::WindowCloseButtonHint | Qt::WindowSystemMenuHint),
|
: QDialog(parent),
|
||||||
ui(std::make_unique<Ui::DirectConnect>()), system{system_}, room_network{
|
ui(std::make_unique<Ui::DirectConnect>()), system{system_}, room_network{
|
||||||
system.GetRoomNetwork()} {
|
system.GetRoomNetwork()} {
|
||||||
|
|
||||||
|
const bool is_gamescope = !qgetenv("GAMESCOPE_WIDTH").isEmpty() || qgetenv("XDG_CURRENT_DESKTOP") == "gamescope";
|
||||||
|
if (is_gamescope) {
|
||||||
|
setWindowFlags(Qt::Window | Qt::WindowTitleHint | Qt::WindowStaysOnTopHint);
|
||||||
|
} else {
|
||||||
|
setWindowFlags(Qt::WindowTitleHint | Qt::WindowCloseButtonHint | Qt::WindowSystemMenuHint);
|
||||||
|
}
|
||||||
|
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
|
|
||||||
// setup the watcher for background connections
|
// setup the watcher for background connections
|
||||||
|
|||||||
Reference in New Issue
Block a user