mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-12-08 23:47:42 +00:00
MP1: Migrate from std::bind to lambdas
Provides a more straightforward means of supplying custom behavior in place. Lambdas also typically optimize better compared to std::bind objects.
This commit is contained in:
@@ -101,9 +101,9 @@ bool CSaveGameScreen::PumpLoad() {
|
||||
x64_textpane_choice2 = static_cast<CGuiTextPane*>(x50_loadedFrame->FindWidget("textpane_choice2"));
|
||||
x68_textpane_choice3 = static_cast<CGuiTextPane*>(x50_loadedFrame->FindWidget("textpane_choice3"));
|
||||
|
||||
x58_tablegroup_choices->SetMenuAdvanceCallback(std::bind(&CSaveGameScreen::DoAdvance, this, std::placeholders::_1));
|
||||
x58_tablegroup_choices->SetMenuAdvanceCallback([this](CGuiTableGroup* caller) { DoAdvance(caller); });
|
||||
x58_tablegroup_choices->SetMenuSelectionChangeCallback(
|
||||
std::bind(&CSaveGameScreen::DoSelectionChange, this, std::placeholders::_1, std::placeholders::_2));
|
||||
[this](CGuiTableGroup* caller, int oldSel) { DoSelectionChange(caller, oldSel); });
|
||||
|
||||
if (x0_saveCtx == ESaveContext::InGame)
|
||||
x6c_cardDriver->StartCardProbe();
|
||||
|
||||
Reference in New Issue
Block a user