mirror of
https://git.eden-emu.dev/archive/citron
synced 2026-04-14 00:30:51 -04:00
fix(gamescope): Restructure Multiplayer Dialogs for Gamescope
Signed-off-by: Collecting <collecting@noreply.localhost>
This commit is contained in:
@@ -32,10 +32,23 @@
|
|||||||
HostRoomWindow::HostRoomWindow(QWidget* parent, QStandardItemModel* list,
|
HostRoomWindow::HostRoomWindow(QWidget* parent, QStandardItemModel* list,
|
||||||
std::shared_ptr<Core::AnnounceMultiplayerSession> session,
|
std::shared_ptr<Core::AnnounceMultiplayerSession> session,
|
||||||
Core::System& system_)
|
Core::System& system_)
|
||||||
: QDialog(parent, Qt::WindowTitleHint | Qt::WindowCloseButtonHint | Qt::WindowSystemMenuHint),
|
: QDialog(parent),
|
||||||
ui(std::make_unique<Ui::HostRoom>()),
|
ui(std::make_unique<Ui::HostRoom>()),
|
||||||
announce_multiplayer_session(session), system{system_}, room_network{
|
announce_multiplayer_session(session), system{system_}, room_network{
|
||||||
system.GetRoomNetwork()} {
|
system.GetRoomNetwork()} {
|
||||||
|
|
||||||
|
const bool is_gamescope = UISettings::IsGamescope();
|
||||||
|
if (is_gamescope) {
|
||||||
|
setWindowFlags(Qt::Window | Qt::CustomizeWindowHint | Qt::WindowTitleHint);
|
||||||
|
setWindowModality(Qt::NonModal);
|
||||||
|
|
||||||
|
int w = 800;
|
||||||
|
int h = 500;
|
||||||
|
setFixedSize(w, h);
|
||||||
|
} else {
|
||||||
|
setWindowFlags(Qt::Dialog | Qt::WindowTitleHint | Qt::WindowCloseButtonHint | Qt::WindowSystemMenuHint);
|
||||||
|
}
|
||||||
|
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
|
|
||||||
// set up validation for all of the fields
|
// set up validation for all of the fields
|
||||||
|
|||||||
Reference in New Issue
Block a user