From 2b90451c4a5645e5d06082df383cc0478f00f7df Mon Sep 17 00:00:00 2001 From: lightningterror <18107717+lightningterror@users.noreply.github.com> Date: Fri, 26 Jan 2024 18:45:30 +0100 Subject: [PATCH] Qt: Fix more compiler warnings. -Wsign-compare, -Wunused-variable. --- pcsx2-qt/Debugger/DebuggerSettingsManager.cpp | 6 +++--- pcsx2-qt/Settings/DEV9SettingsWidget.cpp | 2 -- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/pcsx2-qt/Debugger/DebuggerSettingsManager.cpp b/pcsx2-qt/Debugger/DebuggerSettingsManager.cpp index 4151278a4b9d4..dd7841479b693 100644 --- a/pcsx2-qt/Debugger/DebuggerSettingsManager.cpp +++ b/pcsx2-qt/Debugger/DebuggerSettingsManager.cpp @@ -141,15 +141,15 @@ void DebuggerSettingsManager::saveGameSettings(QAbstractTableModel* abstractTabl QJsonObject loadedSettings = loadGameSettingsJSON(); QJsonArray rowsArray; QStringList keys; - for (u32 col = 0; col < abstractTableModel->columnCount(); ++col) + for (int col = 0; col < abstractTableModel->columnCount(); ++col) { keys << abstractTableModel->headerData(col, Qt::Horizontal, Qt::UserRole).toString(); } - for (u32 row = 0; row < abstractTableModel->rowCount(); row++) + for (int row = 0; row < abstractTableModel->rowCount(); row++) { QJsonObject rowObject; - for (u32 col = 0; col < abstractTableModel->columnCount(); col++) + for (int col = 0; col < abstractTableModel->columnCount(); col++) { const QModelIndex index = abstractTableModel->index(row, col); const QString data = abstractTableModel->data(index, role).toString(); diff --git a/pcsx2-qt/Settings/DEV9SettingsWidget.cpp b/pcsx2-qt/Settings/DEV9SettingsWidget.cpp index fc431bed3b372..706ae0691e81d 100644 --- a/pcsx2-qt/Settings/DEV9SettingsWidget.cpp +++ b/pcsx2-qt/Settings/DEV9SettingsWidget.cpp @@ -724,8 +724,6 @@ void DEV9SettingsWidget::onHddSizeAccessorSpin() void DEV9SettingsWidget::onHddLBA48Changed(int state) { - const bool enabled = state; - m_ui.hddSizeSlider->setMaximum(state ? 2000 : 120); m_ui.hddSizeSpinBox->setMaximum(state ? 2000 : 120); m_ui.hddSizeMaxLabel->setText(state ? tr("2000") : tr("120"));