mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-04 13:42:55 +01:00
Fix Intent pointers/strings
This commit is contained in:
committed by
Michał Janiszewski
parent
221e42b56e
commit
e5ce3859a3
@@ -14,6 +14,8 @@
|
||||
*****************************************************************************/
|
||||
#pragma endregion
|
||||
|
||||
#include <string>
|
||||
|
||||
#include <openrct2/config/Config.h>
|
||||
#include <openrct2/title/TitleScreen.h>
|
||||
#include <openrct2/core/Memory.hpp>
|
||||
@@ -836,7 +838,7 @@ static void window_loadsave_select(rct_window *w, const char *path)
|
||||
{
|
||||
save_path(&gConfigGeneral.last_save_track_directory, pathBuffer);
|
||||
auto intent = Intent(WC_INSTALL_TRACK);
|
||||
intent.putExtra(INTENT_EXTRA_PATH, pathBuffer);
|
||||
intent.putExtra(INTENT_EXTRA_PATH, std::string { pathBuffer });
|
||||
context_open_intent(&intent);
|
||||
window_close_by_class(WC_LOADSAVE);
|
||||
window_loadsave_invoke_callback(MODAL_RESULT_OK, pathBuffer);
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
*****************************************************************************/
|
||||
#pragma endregion
|
||||
|
||||
#include <string>
|
||||
|
||||
#include "../Context.h"
|
||||
#include "../OpenRCT2.h"
|
||||
|
||||
@@ -292,7 +294,7 @@ void window_editor_bottom_toolbar_jump_forward_to_save_scenario()
|
||||
window_close_all();
|
||||
auto intent = Intent(WC_LOADSAVE);
|
||||
intent.putExtra(INTENT_EXTRA_LOADSAVE_TYPE, LOADSAVETYPE_SAVE | LOADSAVETYPE_SCENARIO);
|
||||
intent.putExtra(INTENT_EXTRA_PATH, gS6Info.name);
|
||||
intent.putExtra(INTENT_EXTRA_PATH, std::string { gS6Info.name });
|
||||
context_open_intent(&intent);
|
||||
}
|
||||
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
*****************************************************************************/
|
||||
#pragma endregion
|
||||
|
||||
#include <string>
|
||||
|
||||
#include "../config/Config.h"
|
||||
#include "../Context.h"
|
||||
#include "../OpenRCT2.h"
|
||||
@@ -560,7 +562,7 @@ static void window_top_toolbar_dropdown(rct_window *w, rct_widgetindex widgetInd
|
||||
if (gScreenFlags & SCREEN_FLAGS_SCENARIO_EDITOR) {
|
||||
auto intent = Intent(WC_LOADSAVE);
|
||||
intent.putExtra(INTENT_EXTRA_LOADSAVE_TYPE, LOADSAVETYPE_SAVE | LOADSAVETYPE_LANDSCAPE);
|
||||
intent.putExtra(INTENT_EXTRA_PATH, gS6Info.name);
|
||||
intent.putExtra(INTENT_EXTRA_PATH, std::string { gS6Info.name });
|
||||
context_open_intent(&intent);
|
||||
}
|
||||
else {
|
||||
|
||||
Reference in New Issue
Block a user