20 Commits

Author SHA1 Message Date
e9b57393a6 Merge pull request #13766 from JosJuice/powerpc-missing-updates
PowerPC: Add missing SDRUpdated/MSRUpdated calls
2025-06-24 16:36:49 -04:00
97febd9477 Merge pull request #13763 from Dentomologist/mainwindow_show_hardcore_mode_error_for_recording_playback
MainWindow: Show hardcore mode error for recording playback
2025-06-24 16:35:56 -04:00
0946814711 Merge pull request #13761 from Dentomologist/qt_use_nonautodismissiblemenu_in_more_places
Qt: Use NonAutodismissibleMenu in more places
2025-06-24 16:35:40 -04:00
3627cfb7b1 Merge pull request #13758 from Dentomologist/threadwidget_fix_line_edit_margins
ThreadWidget: Fix line edit margins
2025-06-24 16:35:12 -04:00
2e8da29ca2 Merge pull request #13756 from Tilka/price_is_right
GameSettings: some updates
2025-06-24 16:34:47 -04:00
f7fa59e05d Merge pull request #13754 from SuperSamus/nsmbw-pal-remove-speedhack
GameINI: Remove NSMBW PAL speed hack
2025-06-24 16:34:27 -04:00
fbced5d0f5 Merge pull request #13774 from Tilka/cp_cleanup
VideoCommon: remove unused struct fields
2025-06-24 14:41:25 -05:00
59d2611a94 VideoCommon: remove unused struct fields 2025-06-24 19:38:45 +01:00
e002fcdf2f PowerPC: Use SPR_LR constant in an additional location 2025-06-20 10:42:47 +02:00
8c643693a9 PowerPC: Add missing SDRUpdated/MSRUpdated calls 2025-06-20 10:42:43 +02:00
e21ae90073 MainWindow: Show hardcore mode error for recording playback
Show an error message when attempting to play an input recording while
RetroAchievements hardcore mode is active, instead of silently doing
nothing.
2025-06-17 12:21:39 -07:00
c488545091 GameListModel: Update tag list and sorting immediately
Emit the dataChanged signal when adding or removing tags from a game.
This both updates the contents of the game's Tags column immediately
(instead of having to wait for the context menu to be closed), and
updates the sorting if games are being sorted by the Tags column.
2025-06-16 22:58:30 -07:00
2fd74990b7 Qt: Use NonAutodismissibleMenu in more places
Use NonAutodismissibleMenu for MenuBar's Options, JIT, and
Tools->"Connect Wii Remotes" menus, as well as for the Tags menu in
GameList's context menu.

NonAutodismissibleMenu allows users to check or uncheck multiple
checkable menu items without closing the menu between selections.
2025-06-16 22:56:26 -07:00
ab25632992 ThreadWidget: Don't set fixed width on QLineEdits
Fix clipping of QLineEdit contents by having them take up half the grid
width instead of trying to match the contents width in an unreliable
manner.
2025-06-16 22:33:20 -07:00
6a0d8ca3f8 MenuBar: Rename menu variable
The Tools menu has a number of submenus, so rename menu to
connect_wii_remotes_menu for clarity.
2025-06-16 21:06:55 -07:00
ca004e35f7 GameSettings: add performance hack for Baby And Me
The patch is not enabled by default.
2025-06-16 20:08:36 +01:00
c39b067479 GameSettings: don't force EFB-to-tex for Fireblade
This ini is from the initial mega commit. The game seems to work fine
without it.
2025-06-16 19:48:31 +01:00
58b86074ae GameSettings: fix purple flickering in Trivial Pursuit - Bet You Know It 2025-06-16 19:48:31 +01:00
cc5933a6ce GameSettings: fix purple screen in The Price Is Right 2025-06-16 19:48:31 +01:00
46ce355d93 GameINI: Remove NSMBW PAL speed hack 2025-06-13 22:27:21 +02:00
14 changed files with 71 additions and 36 deletions

View File

@ -1,14 +0,0 @@
# GFBE5D - FireBlade
[Core]
# Values set here will override the main Dolphin settings.
[OnFrame]
# Add memory patches to be applied every frame here.
[ActionReplay]
# Add action replay cheats here.
[Video_Hacks]
EFBToTextureEnable = True

View File

@ -0,0 +1,8 @@
# R6APPU - Baby and Me
[OnFrame]
# The game busyloops for frame pacing but not in a way Dolphin can
# currently optimize, so lots of CPU time is wasted.
# This patch adds a call to VIWaitForRetrace to avoid this.
$Performance hack
0x80016E28:dword:0x4807BD89

View File

@ -13,4 +13,7 @@
SuggestedAspectRatio = 2
[Video_Hacks]
# Avoid purple screen.
XFBToTextureEnable = False
# Make Wiimote pointer visible.
ImmediateXFBEnable = False

View File

@ -0,0 +1,5 @@
# S7BE69, S7BP69 - Trivial Pursuit: Bet You Know It
[Video_Hacks]
# Avoid purple flickering.
XFBToTextureEnable = False

View File

@ -2,9 +2,6 @@
[OnFrame]
# Add memory patches to be applied every frame here.
$Speed hack
0x801D5B10:dword:0x60000000
0x801D5B14:dword:0x60000000
[ActionReplay]
# Add action replay cheats here.

View File

@ -447,9 +447,15 @@ void Expression::SynchronizeBindings(Core::System& system, SynchronizeDirection
break;
case VarBindingType::SPR:
if (dir == SynchronizeDirection::From)
{
v->value = static_cast<double>(ppc_state.spr[bind->index]);
}
else
{
ppc_state.spr[bind->index] = static_cast<u32>(static_cast<s64>(v->value));
if (bind->index == SPR_SDR)
system.GetMMU().SDRUpdated();
}
break;
case VarBindingType::PCtr:
if (dir == SynchronizeDirection::From)
@ -457,9 +463,14 @@ void Expression::SynchronizeBindings(Core::System& system, SynchronizeDirection
break;
case VarBindingType::MSR:
if (dir == SynchronizeDirection::From)
{
v->value = static_cast<double>(ppc_state.msr.Hex);
}
else
{
ppc_state.msr.Hex = static_cast<u32>(static_cast<s64>(v->value));
PowerPC::MSRUpdated(ppc_state);
}
break;
}
}

View File

@ -684,6 +684,7 @@ static void WriteRegister()
break;
case 104:
ppc_state.spr[SPR_SDR] = re32hex(bufptr);
system.GetMMU().SDRUpdated();
break;
case 105:
ppc_state.spr[SPR_ASR] = re64hex(bufptr);

View File

@ -102,7 +102,7 @@ void Interpreter::Trace(const UGeckoInstruction& inst)
"INTER PC: {:08x} SRR0: {:08x} SRR1: {:08x} CRval: {:016x} "
"FPSCR: {:08x} MSR: {:08x} LR: {:08x} {} {:08x} {}",
m_ppc_state.pc, SRR0(m_ppc_state), SRR1(m_ppc_state), m_ppc_state.cr.fields[0],
m_ppc_state.fpscr.Hex, m_ppc_state.msr.Hex, m_ppc_state.spr[8], regs, inst.hex,
m_ppc_state.fpscr.Hex, m_ppc_state.msr.Hex, m_ppc_state.spr[SPR_LR], regs, inst.hex,
ppc_inst);
}

View File

@ -137,8 +137,7 @@ QLineEdit* ThreadWidget::CreateLineEdit() const
{
QLineEdit* line_edit = new QLineEdit(QStringLiteral("00000000"));
line_edit->setReadOnly(true);
line_edit->setFixedWidth(
line_edit->fontMetrics().boundingRect(QStringLiteral(" 00000000 ")).width());
line_edit->setAlignment(Qt::AlignVCenter | Qt::AlignRight);
return line_edit;
}
@ -146,6 +145,8 @@ QGroupBox* ThreadWidget::CreateContextGroup()
{
QGroupBox* context_group = new QGroupBox(tr("Thread context"));
QGridLayout* context_layout = new QGridLayout;
context_layout->setColumnStretch(0, 1);
context_layout->setColumnStretch(1, 1);
context_group->setLayout(context_layout);
context_layout->addWidget(new QLabel(tr("Current context")), 0, 0);
m_current_context = CreateLineEdit();
@ -164,6 +165,8 @@ QGroupBox* ThreadWidget::CreateActiveThreadQueueGroup()
{
QGroupBox* thread_queue_group = new QGroupBox(tr("Active thread queue"));
auto* thread_queue_layout = new QGridLayout;
thread_queue_layout->setColumnStretch(0, 1);
thread_queue_layout->setColumnStretch(1, 1);
thread_queue_group->setLayout(thread_queue_layout);
thread_queue_layout->addWidget(new QLabel(tr("Head")), 0, 0);
m_queue_head = CreateLineEdit();

View File

@ -66,6 +66,7 @@
#include "DolphinQt/QtUtils/DolphinFileDialog.h"
#include "DolphinQt/QtUtils/DoubleClickEventFilter.h"
#include "DolphinQt/QtUtils/ModalMessageBox.h"
#include "DolphinQt/QtUtils/NonAutodismissibleMenu.h"
#include "DolphinQt/QtUtils/ParallelProgressDialog.h"
#include "DolphinQt/Resources.h"
#include "DolphinQt/Settings.h"
@ -519,7 +520,8 @@ void GameList::ShowContextMenu(const QPoint&)
menu->addSeparator();
auto* tags_menu = menu->addMenu(tr("Tags"));
auto* const tags_menu{new QtUtils::NonAutodismissibleMenu(tr("Tags"), menu)};
menu->addMenu(tags_menu);
auto path = game->GetFilePath();
auto game_tags = m_model.GetGameTags(path);

View File

@ -470,6 +470,13 @@ void GameListModel::AddGameTag(const std::string& path, const QString& name)
m_game_tags[QString::fromStdString(path)] = tags;
Settings::GetQSettings().setValue(QStringLiteral("gamelist/game_tags"), m_game_tags);
const int row = FindGameIndex(path);
if (row >= 0)
{
const QModelIndex index = createIndex(row, static_cast<int>(Column::Tags));
emit dataChanged(index, index);
}
}
void GameListModel::RemoveGameTag(const std::string& path, const QString& name)
@ -481,6 +488,13 @@ void GameListModel::RemoveGameTag(const std::string& path, const QString& name)
m_game_tags[QString::fromStdString(path)] = tags;
Settings::GetQSettings().setValue(QStringLiteral("gamelist/game_tags"), m_game_tags);
const int row = FindGameIndex(path);
if (row >= 0)
{
const QModelIndex index = createIndex(row, static_cast<int>(Column::Tags));
emit dataChanged(index, index);
}
}
void GameListModel::NewTag(const QString& name)

View File

@ -1849,6 +1849,14 @@ void MainWindow::OnImportNANDBackup()
void MainWindow::OnPlayRecording()
{
if (AchievementManager::GetInstance().IsHardcoreModeActive())
{
ModalMessageBox::critical(
this, tr("Error"),
tr("Playback of input recordings is disabled in RetroAchievements hardcore mode."));
return;
}
QString dtm_file = DolphinFileDialog::getOpenFileName(
this, tr("Select the Recording File to Play"), QString(), tr("Dolphin TAS Movies (*.dtm)"));

View File

@ -352,22 +352,23 @@ void MenuBar::AddToolsMenu()
m_export_wii_saves =
tools_menu->addAction(tr("Export All Wii Saves"), this, &MenuBar::ExportWiiSaves);
QMenu* menu = new QMenu(tr("Connect Wii Remotes"), tools_menu);
auto* const connect_wii_remotes_menu{
new QtUtils::NonAutodismissibleMenu(tr("Connect Wii Remotes"), tools_menu)};
tools_menu->addSeparator();
tools_menu->addMenu(menu);
tools_menu->addMenu(connect_wii_remotes_menu);
for (int i = 0; i < 4; i++)
{
m_wii_remotes[i] = menu->addAction(tr("Connect Wii Remote %1").arg(i + 1), this,
[this, i] { emit ConnectWiiRemote(i); });
m_wii_remotes[i] = connect_wii_remotes_menu->addAction(
tr("Connect Wii Remote %1").arg(i + 1), this, [this, i] { emit ConnectWiiRemote(i); });
m_wii_remotes[i]->setCheckable(true);
}
menu->addSeparator();
connect_wii_remotes_menu->addSeparator();
m_wii_remotes[4] =
menu->addAction(tr("Connect Balance Board"), this, [this] { emit ConnectWiiRemote(4); });
m_wii_remotes[4] = connect_wii_remotes_menu->addAction(tr("Connect Balance Board"), this,
[this] { emit ConnectWiiRemote(4); });
m_wii_remotes[4]->setCheckable(true);
}
@ -601,7 +602,8 @@ void MenuBar::AddViewMenu()
void MenuBar::AddOptionsMenu()
{
QMenu* options_menu = addMenu(tr("&Options"));
auto* const options_menu{new QtUtils::NonAutodismissibleMenu(tr("&Options"), this)};
addMenu(options_menu);
#if QT_VERSION >= QT_VERSION_CHECK(6, 4, 0)
options_menu->addAction(tr("Co&nfiguration"), QKeySequence::Preferences, this,
&MenuBar::Configure);
@ -892,7 +894,8 @@ void MenuBar::AddMovieMenu()
void MenuBar::AddJITMenu()
{
m_jit = addMenu(tr("JIT"));
m_jit = new QtUtils::NonAutodismissibleMenu(tr("JIT"), this);
addMenu(m_jit);
m_jit_interpreter_core = m_jit->addAction(tr("Interpreter Core"));
m_jit_interpreter_core->setCheckable(true);

View File

@ -200,12 +200,6 @@ private:
u16 m_perf_select = 0;
u16 m_unk_0a_reg = 0;
u16 m_bbox_left = 0;
u16 m_bbox_top = 0;
u16 m_bbox_right = 0;
u16 m_bbox_bottom = 0;
u16 m_token_reg = 0;
Common::Flag m_interrupt_set;
Common::Flag m_interrupt_waiting;