DolphinQt: Remove Windows dialog help buttons

This commit is contained in:
Dentomologist
2021-08-21 10:35:21 -07:00
parent 17a01c894b
commit 87924f2ddd
4 changed files with 37 additions and 24 deletions

View File

@ -1270,9 +1270,11 @@ void MenuBar::GenerateSymbolsFromRSO()
if (ret == QMessageBox::Yes)
return GenerateSymbolsFromRSOAuto();
QString text = QInputDialog::getText(this, tr("Input"), tr("Enter the RSO module address:"));
const QString text =
QInputDialog::getText(this, tr("Input"), tr("Enter the RSO module address:"),
QLineEdit::Normal, QString{}, nullptr, Qt::WindowCloseButtonHint);
bool good;
uint address = text.toUInt(&good, 16);
const uint address = text.toUInt(&good, 16);
if (!good)
{
@ -1308,7 +1310,7 @@ void MenuBar::GenerateSymbolsFromRSOAuto()
});
progress.GetRaw()->exec();
auto matches = future.get();
const auto matches = future.get();
QStringList items;
for (const auto& match : matches)
@ -1324,8 +1326,9 @@ void MenuBar::GenerateSymbolsFromRSOAuto()
}
bool ok;
const QString item = QInputDialog::getItem(
this, tr("Input"), tr("Select the RSO module address:"), items, 0, false, &ok);
const QString item =
QInputDialog::getItem(this, tr("Input"), tr("Select the RSO module address:"), items, 0,
false, &ok, Qt::WindowCloseButtonHint);
if (!ok)
return;
@ -1570,7 +1573,8 @@ void MenuBar::TrySaveSymbolMap(const QString& path)
void MenuBar::CreateSignatureFile()
{
const QString text = QInputDialog::getText(
this, tr("Input"), tr("Only export symbols with prefix:\n(Blank for all symbols)"));
this, tr("Input"), tr("Only export symbols with prefix:\n(Blank for all symbols)"),
QLineEdit::Normal, QString{}, nullptr, Qt::WindowCloseButtonHint);
const QString file = QFileDialog::getSaveFileName(this, tr("Save signature file"),
QDir::homePath(), GetSignatureSelector());
@ -1594,7 +1598,8 @@ void MenuBar::CreateSignatureFile()
void MenuBar::AppendSignatureFile()
{
const QString text = QInputDialog::getText(
this, tr("Input"), tr("Only append symbols with prefix:\n(Blank for all symbols)"));
this, tr("Input"), tr("Only append symbols with prefix:\n(Blank for all symbols)"),
QLineEdit::Normal, QString{}, nullptr, Qt::WindowCloseButtonHint);
const QString file = QFileDialog::getSaveFileName(this, tr("Append signature to"),
QDir::homePath(), GetSignatureSelector());
@ -1685,8 +1690,9 @@ void MenuBar::LogInstructions()
void MenuBar::SearchInstruction()
{
bool good;
const QString op = QInputDialog::getText(this, tr("Search instruction"), tr("Instruction:"),
QLineEdit::Normal, QString{}, &good);
const QString op =
QInputDialog::getText(this, tr("Search instruction"), tr("Instruction:"), QLineEdit::Normal,
QString{}, &good, Qt::WindowCloseButtonHint);
if (!good)
return;
@ -1695,7 +1701,7 @@ void MenuBar::SearchInstruction()
for (u32 addr = Memory::MEM1_BASE_ADDR; addr < Memory::MEM1_BASE_ADDR + Memory::GetRamSizeReal();
addr += 4)
{
auto ins_name =
const auto ins_name =
QString::fromStdString(PPCTables::GetInstructionName(PowerPC::HostRead_U32(addr)));
if (op == ins_name)
{