mirror of
https://github.com/RPCS3/rpcs3.git
synced 2024-11-22 02:32:36 +01:00
Fixed behaviour of buttons in Welcome, Find, Settings, VFS and Debugger dialogs - now reacting to button click, not press
This commit is contained in:
parent
ab228d6407
commit
2016a33277
@ -33,10 +33,10 @@ find_dialog::find_dialog(QTextEdit* edit, QWidget *parent, Qt::WindowFlags f) :
|
||||
layout->addLayout(button_layout);
|
||||
setLayout(layout);
|
||||
|
||||
connect(m_find_first, &QPushButton::pressed, this, &find_dialog::find_first);
|
||||
connect(m_find_last, &QPushButton::pressed, this, &find_dialog::find_last);
|
||||
connect(m_find_next, &QPushButton::pressed, this, &find_dialog::find_next);
|
||||
connect(m_find_previous, &QPushButton::pressed, this, &find_dialog::find_previous);
|
||||
connect(m_find_first, &QPushButton::clicked, this, &find_dialog::find_first);
|
||||
connect(m_find_last, &QPushButton::clicked, this, &find_dialog::find_last);
|
||||
connect(m_find_next, &QPushButton::clicked, this, &find_dialog::find_next);
|
||||
connect(m_find_previous, &QPushButton::clicked, this, &find_dialog::find_previous);
|
||||
|
||||
show();
|
||||
}
|
||||
|
@ -65,7 +65,7 @@ instruction_editor_dialog::instruction_editor_dialog(QWidget *parent, u32 _pc, c
|
||||
setModal(true);
|
||||
|
||||
// Events
|
||||
connect(button_ok, &QAbstractButton::pressed, [=]()
|
||||
connect(button_ok, &QAbstractButton::clicked, [=]()
|
||||
{
|
||||
bool ok;
|
||||
ulong opcode = m_instr->text().toULong(&ok, 16);
|
||||
@ -89,7 +89,7 @@ instruction_editor_dialog::instruction_editor_dialog(QWidget *parent, u32 _pc, c
|
||||
|
||||
accept();
|
||||
});
|
||||
connect(button_cancel, &QAbstractButton::pressed, this, &instruction_editor_dialog::reject);
|
||||
connect(button_cancel, &QAbstractButton::clicked, this, &instruction_editor_dialog::reject);
|
||||
connect(m_instr, &QLineEdit::textChanged, this, &instruction_editor_dialog::updatePreview);
|
||||
|
||||
updatePreview();
|
||||
|
@ -73,8 +73,8 @@ register_editor_dialog::register_editor_dialog(QWidget *parent, u32 _pc, const s
|
||||
setModal(true);
|
||||
|
||||
// Events
|
||||
connect(button_ok, &QAbstractButton::pressed, this, [=](){OnOkay(_cpu); accept();});
|
||||
connect(button_cancel, &QAbstractButton::pressed, this, ®ister_editor_dialog::reject);
|
||||
connect(button_ok, &QAbstractButton::clicked, this, [=](){OnOkay(_cpu); accept();});
|
||||
connect(button_cancel, &QAbstractButton::clicked, this, ®ister_editor_dialog::reject);
|
||||
connect(m_register_combo, &QComboBox::currentTextChanged, this, ®ister_editor_dialog::updateRegister);
|
||||
|
||||
updateRegister(m_register_combo->currentText());
|
||||
|
@ -249,7 +249,7 @@ settings_dialog::settings_dialog(std::shared_ptr<gui_settings> guiSettings, std:
|
||||
ppuBG->button(i)->setChecked(true);
|
||||
}
|
||||
|
||||
connect(ppuBG->button(i), &QAbstractButton::pressed, [=]()
|
||||
connect(ppuBG->button(i), &QAbstractButton::clicked, [=]()
|
||||
{
|
||||
xemu_settings->SetSetting(emu_settings::PPUDecoder, sstr(ppu_list[i]));
|
||||
});
|
||||
@ -279,7 +279,7 @@ settings_dialog::settings_dialog(std::shared_ptr<gui_settings> guiSettings, std:
|
||||
spuBG->button(i)->setChecked(true);
|
||||
}
|
||||
|
||||
connect(spuBG->button(i), &QAbstractButton::pressed, [=]()
|
||||
connect(spuBG->button(i), &QAbstractButton::clicked, [=]()
|
||||
{
|
||||
xemu_settings->SetSetting(emu_settings::SPUDecoder, sstr(spu_list[i]));
|
||||
});
|
||||
@ -329,7 +329,7 @@ settings_dialog::settings_dialog(std::shared_ptr<gui_settings> guiSettings, std:
|
||||
libModeBG->button(i)->setChecked(true);
|
||||
}
|
||||
|
||||
connect(libModeBG->button(i), &QAbstractButton::pressed, [=]()
|
||||
connect(libModeBG->button(i), &QAbstractButton::clicked, [=]()
|
||||
{
|
||||
xemu_settings->SetSetting(emu_settings::LibLoadOptions, sstr(libmode_list[i]));
|
||||
});
|
||||
@ -907,7 +907,7 @@ settings_dialog::settings_dialog(std::shared_ptr<gui_settings> guiSettings, std:
|
||||
enterButtonAssignmentBG->button(i)->setChecked(true);
|
||||
}
|
||||
|
||||
connect(enterButtonAssignmentBG->button(i), &QAbstractButton::pressed, [=]()
|
||||
connect(enterButtonAssignmentBG->button(i), &QAbstractButton::clicked, [=]()
|
||||
{
|
||||
xemu_settings->SetSetting(emu_settings::EnterButtonAssignment, sstr(assignable_buttons[i]));
|
||||
});
|
||||
|
@ -36,19 +36,19 @@ vfs_dialog::vfs_dialog(std::shared_ptr<gui_settings> guiSettings, std::shared_pt
|
||||
|
||||
// Create buttons
|
||||
QPushButton* addDir = new QPushButton(tr("Add New Directory"));
|
||||
connect(addDir, &QAbstractButton::pressed, [=]
|
||||
connect(addDir, &QAbstractButton::clicked, [=]
|
||||
{
|
||||
static_cast<vfs_dialog_tab*>(tabs->currentWidget())->AddNewDirectory();
|
||||
});
|
||||
|
||||
QPushButton* reset = new QPushButton(tr("Reset"));
|
||||
connect(reset, &QAbstractButton::pressed, [=]
|
||||
connect(reset, &QAbstractButton::clicked, [=]
|
||||
{
|
||||
static_cast<vfs_dialog_tab*>(tabs->currentWidget())->Reset();
|
||||
});
|
||||
|
||||
QPushButton* resetAll = new QPushButton(tr("Reset All"));
|
||||
connect(resetAll, &QAbstractButton::pressed, [=]
|
||||
connect(resetAll, &QAbstractButton::clicked, [=]
|
||||
{
|
||||
for (int i = 0; i < tabs->count(); ++i)
|
||||
{
|
||||
@ -60,7 +60,7 @@ vfs_dialog::vfs_dialog(std::shared_ptr<gui_settings> guiSettings, std::shared_pt
|
||||
okay->setAutoDefault(true);
|
||||
okay->setDefault(true);
|
||||
|
||||
connect(okay, &QAbstractButton::pressed, [=]
|
||||
connect(okay, &QAbstractButton::clicked, [=]
|
||||
{
|
||||
for (int i = 0; i < tabs->count(); ++i)
|
||||
{
|
||||
|
@ -31,7 +31,7 @@ welcome_dialog::welcome_dialog(QWidget* parent) : QDialog(parent), ui(new Ui::we
|
||||
settings->SetValue(gui::ib_show_welcome, QVariant(!checked));
|
||||
});
|
||||
|
||||
connect(ui->okay, &QPushButton::pressed, this, &QDialog::accept);
|
||||
connect(ui->okay, &QPushButton::clicked, this, &QDialog::accept);
|
||||
|
||||
layout()->setSizeConstraint(QLayout::SetFixedSize);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user