mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 06:09:50 -06:00
DolphinQt: Set window decorations for all top-level QWidgets.
This commit is contained in:
@ -11,6 +11,7 @@
|
||||
|
||||
#include "Core/FreeLookManager.h"
|
||||
#include "DolphinQt/Config/ControllerInterface/ControllerInterfaceWindow.h"
|
||||
#include "DolphinQt/QtUtils/SetWindowDecorations.h"
|
||||
#include "InputCommon/InputConfig.h"
|
||||
|
||||
FreeLookRotation::FreeLookRotation(MappingWindow* window) : MappingWidget(window)
|
||||
@ -33,6 +34,7 @@ void FreeLookRotation::CreateMainLayout()
|
||||
ControllerInterfaceWindow* window = new ControllerInterfaceWindow(this);
|
||||
window->setAttribute(Qt::WA_DeleteOnClose, true);
|
||||
window->setWindowModality(Qt::WindowModality::WindowModal);
|
||||
SetQWidgetWindowDecorations(window);
|
||||
window->show();
|
||||
});
|
||||
m_main_layout->addLayout(alternate_input_layout, 0, 0, 1, -1);
|
||||
|
@ -12,6 +12,7 @@
|
||||
#include "DolphinQt/Config/Mapping/MappingCommon.h"
|
||||
#include "DolphinQt/Config/Mapping/MappingWidget.h"
|
||||
#include "DolphinQt/Config/Mapping/MappingWindow.h"
|
||||
#include "DolphinQt/QtUtils/SetWindowDecorations.h"
|
||||
|
||||
#include "InputCommon/ControlReference/ControlReference.h"
|
||||
#include "InputCommon/ControllerEmu/ControlGroup/Buttons.h"
|
||||
@ -97,6 +98,7 @@ void MappingButton::AdvancedPressed()
|
||||
{
|
||||
IOWindow io(m_parent, m_parent->GetController(), m_reference,
|
||||
m_reference->IsInput() ? IOWindow::Type::Input : IOWindow::Type::Output);
|
||||
SetQWidgetWindowDecorations(&io);
|
||||
io.exec();
|
||||
|
||||
ConfigChanged();
|
||||
|
@ -16,6 +16,7 @@
|
||||
#include "DolphinQt/Config/Mapping/MappingIndicator.h"
|
||||
#include "DolphinQt/Config/Mapping/MappingNumeric.h"
|
||||
#include "DolphinQt/Config/Mapping/MappingWindow.h"
|
||||
#include "DolphinQt/QtUtils/SetWindowDecorations.h"
|
||||
|
||||
#include "InputCommon/ControlReference/ControlReference.h"
|
||||
#include "InputCommon/ControllerEmu/Control/Control.h"
|
||||
@ -248,6 +249,7 @@ void MappingWidget::ShowAdvancedControlGroupDialog(ControllerEmu::ControlGroup*
|
||||
// Enable "Close" button functionality.
|
||||
connect(button_box, &QDialogButtonBox::rejected, &dialog, &QDialog::reject);
|
||||
|
||||
SetQWidgetWindowDecorations(&dialog);
|
||||
dialog.exec();
|
||||
}
|
||||
|
||||
@ -303,6 +305,7 @@ MappingWidget::CreateSettingAdvancedMappingButton(ControllerEmu::NumericSettingB
|
||||
setting.SetExpressionFromValue();
|
||||
|
||||
IOWindow io(this, GetController(), &setting.GetInputReference(), IOWindow::Type::Input);
|
||||
SetQWidgetWindowDecorations(&io);
|
||||
io.exec();
|
||||
|
||||
setting.SimplifyIfPossible();
|
||||
|
@ -49,6 +49,7 @@
|
||||
#include "DolphinQt/Config/Mapping/WiimoteEmuMotionControlIMU.h"
|
||||
#include "DolphinQt/QtUtils/ModalMessageBox.h"
|
||||
#include "DolphinQt/QtUtils/NonDefaultQPushButton.h"
|
||||
#include "DolphinQt/QtUtils/SetWindowDecorations.h"
|
||||
#include "DolphinQt/QtUtils/WindowActivationEventFilter.h"
|
||||
#include "DolphinQt/QtUtils/WrapInScrollArea.h"
|
||||
#include "DolphinQt/Settings.h"
|
||||
@ -255,6 +256,7 @@ void MappingWindow::OnDeleteProfilePressed()
|
||||
error.setIcon(QMessageBox::Critical);
|
||||
error.setWindowTitle(tr("Error"));
|
||||
error.setText(tr("The profile '%1' does not exist").arg(profile_name));
|
||||
SetQWidgetWindowDecorations(&error);
|
||||
error.exec();
|
||||
return;
|
||||
}
|
||||
@ -267,6 +269,7 @@ void MappingWindow::OnDeleteProfilePressed()
|
||||
confirm.setInformativeText(tr("This cannot be undone!"));
|
||||
confirm.setStandardButtons(QMessageBox::Yes | QMessageBox::Cancel);
|
||||
|
||||
SetQWidgetWindowDecorations(&confirm);
|
||||
if (confirm.exec() != QMessageBox::Yes)
|
||||
{
|
||||
return;
|
||||
@ -294,6 +297,7 @@ void MappingWindow::OnLoadProfilePressed()
|
||||
error.setIcon(QMessageBox::Critical);
|
||||
error.setWindowTitle(tr("Error"));
|
||||
error.setText(tr("The profile '%1' does not exist").arg(m_profiles_combo->currentText()));
|
||||
SetQWidgetWindowDecorations(&error);
|
||||
error.exec();
|
||||
return;
|
||||
}
|
||||
|
@ -14,6 +14,7 @@
|
||||
#include "Core/HW/WiimoteEmu/WiimoteEmu.h"
|
||||
|
||||
#include "DolphinQt/Config/ControllerInterface/ControllerInterfaceWindow.h"
|
||||
#include "DolphinQt/QtUtils/SetWindowDecorations.h"
|
||||
|
||||
#include "InputCommon/InputConfig.h"
|
||||
|
||||
@ -42,6 +43,7 @@ void WiimoteEmuExtensionMotionInput::CreateNunchukLayout()
|
||||
ControllerInterfaceWindow* window = new ControllerInterfaceWindow(this);
|
||||
window->setAttribute(Qt::WA_DeleteOnClose, true);
|
||||
window->setWindowModality(Qt::WindowModality::WindowModal);
|
||||
SetQWidgetWindowDecorations(window);
|
||||
window->show();
|
||||
});
|
||||
layout->addLayout(warning_layout, 0, 0, 1, -1);
|
||||
|
@ -15,6 +15,7 @@
|
||||
#include "Core/HW/WiimoteEmu/WiimoteEmu.h"
|
||||
|
||||
#include "DolphinQt/Config/ControllerInterface/ControllerInterfaceWindow.h"
|
||||
#include "DolphinQt/QtUtils/SetWindowDecorations.h"
|
||||
|
||||
#include "InputCommon/InputConfig.h"
|
||||
|
||||
@ -40,6 +41,7 @@ void WiimoteEmuMotionControlIMU::CreateMainLayout()
|
||||
ControllerInterfaceWindow* window = new ControllerInterfaceWindow(this);
|
||||
window->setAttribute(Qt::WA_DeleteOnClose, true);
|
||||
window->setWindowModality(Qt::WindowModality::WindowModal);
|
||||
SetQWidgetWindowDecorations(window);
|
||||
window->show();
|
||||
});
|
||||
|
||||
|
Reference in New Issue
Block a user