mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-28 09:14:58 +01:00
Split LOADSAVETYPE_* into LoadSaveAction and LoadSaveType
This commit is contained in:
committed by
GitHub
parent
74c5718b98
commit
8266447904
@@ -257,13 +257,14 @@ public:
|
||||
intent->GetSIntExtra(INTENT_EXTRA_RIDE_ID));
|
||||
case WindowClass::Loadsave:
|
||||
{
|
||||
uint32_t type = intent->GetUIntExtra(INTENT_EXTRA_LOADSAVE_TYPE);
|
||||
auto action = intent->GetEnumExtra<LoadSaveAction>(INTENT_EXTRA_LOADSAVE_ACTION);
|
||||
auto type = intent->GetEnumExtra<LoadSaveType>(INTENT_EXTRA_LOADSAVE_TYPE);
|
||||
std::string defaultPath = intent->GetStringExtra(INTENT_EXTRA_PATH);
|
||||
LoadSaveCallback callback = reinterpret_cast<LoadSaveCallback>(
|
||||
intent->GetCloseCallbackExtra(INTENT_EXTRA_CALLBACK));
|
||||
TrackDesign* trackDesign = static_cast<TrackDesign*>(intent->GetPointerExtra(INTENT_EXTRA_TRACK_DESIGN));
|
||||
auto* w = FileBrowser::OpenPreferred(
|
||||
type, defaultPath,
|
||||
action, type, defaultPath,
|
||||
[callback](ModalResult result, std::string_view path) {
|
||||
if (callback != nullptr)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user