Skip to content

Commit becfd40

Browse files
committed
retro-core: removed the shared rg_app_t pointer, it caused a naming conflict with a lib I'm adding
No real downside here, the pointer wasn't used often and its value is static.
1 parent cc8751f commit becfd40

File tree

9 files changed

+8
-5
lines changed

9 files changed

+8
-5
lines changed

retro-core/main/main.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
#include "shared.h"
22

3-
rg_app_t *app;
4-
53

64
void app_main(void)
75
{
8-
app = rg_system_init(AUDIO_SAMPLE_RATE, NULL, NULL);
6+
rg_app_t *app = rg_system_init(AUDIO_SAMPLE_RATE, NULL, NULL);
97

108
RG_LOGI("configNs=%s", app->configNs);
119

retro-core/main/main_gbc.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ static int autoSaveSRAM_Timer = 0;
1515
static bool useSystemTime = true;
1616
static bool loadBIOSFile = false;
1717

18+
static rg_app_t *app;
1819
static rg_surface_t *updates[2];
1920
static rg_surface_t *currentUpdate;
2021

retro-core/main/main_gw.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ static bool softkey_A_pressed = 0;
2222
static bool softkey_only = 0;
2323
static int softkey_duration = 0;
2424

25+
static rg_app_t *app;
2526
static rg_surface_t *updates[2];
2627
static rg_surface_t *currentUpdate;
2728

retro-core/main/main_lynx.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ static int dpad_mapped_down;
1414
static int dpad_mapped_left;
1515
static int dpad_mapped_right;
1616

17+
static rg_app_t *app;
1718
static rg_surface_t *updates[2];
1819
static rg_surface_t *currentUpdate;
1920
// static bool netplay = false;

retro-core/main/main_nes.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ static bool slowFrame = false;
99
static bool nsfPlayer = false;
1010
static nes_t *nes;
1111

12+
static rg_app_t *app;
1213
static rg_surface_t *updates[2];
1314
static rg_surface_t *currentUpdate;
1415

retro-core/main/main_pce.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ static int skipFrames = 0;
1818
static bool drawFrame = true;
1919
static bool slowFrame = false;
2020

21+
static rg_app_t *app;
2122
static rg_surface_t *updates[2];
2223
static rg_surface_t *currentUpdate;
2324

retro-core/main/main_sms.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
#include <smsplus.h>
44

5+
static rg_app_t *app;
56
static rg_surface_t *updates[2];
67
static rg_surface_t *currentUpdate;
78

retro-core/main/main_snes.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ static const char *SNES_BUTTONS[] = {
6666

6767
#define AUDIO_LOW_PASS_RANGE ((60 * 65536) / 100)
6868

69+
static rg_app_t *app;
6970
static rg_surface_t *updates[2];
7071
static rg_surface_t *currentUpdate;
7172
static rg_audio_sample_t *audioBuffer;

retro-core/main/shared.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@
77
#define AUDIO_SAMPLE_RATE (32000)
88
#define AUDIO_BUFFER_LENGTH (AUDIO_SAMPLE_RATE / 50 + 1)
99

10-
extern rg_app_t *app;
11-
1210
extern uint8_t shared_memory_block_64K[0x10000];
1311

1412
void launcher_main();

0 commit comments

Comments
 (0)