mirror of
https://github.com/Ryujinx/SDL.git
synced 2024-12-23 07:35:38 +00:00
parent
87875a49b4
commit
0e9d050296
|
@ -237,7 +237,7 @@ void PSP_InitOSKeymap(_THIS)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void PSP_EventInit(_THIS)
|
int PSP_EventInit(_THIS)
|
||||||
{
|
{
|
||||||
#ifdef PSPIRKEYB
|
#ifdef PSPIRKEYB
|
||||||
int outputmode = PSP_IRKBD_OUTPUT_MODE_SCANCODE;
|
int outputmode = PSP_IRKBD_OUTPUT_MODE_SCANCODE;
|
||||||
|
@ -251,14 +251,13 @@ void PSP_EventInit(_THIS)
|
||||||
#endif
|
#endif
|
||||||
/* Start thread to read data */
|
/* Start thread to read data */
|
||||||
if ((event_sem = SDL_CreateSemaphore(1)) == NULL) {
|
if ((event_sem = SDL_CreateSemaphore(1)) == NULL) {
|
||||||
SDL_SetError("Can't create input semaphore");
|
return SDL_SetError("Can't create input semaphore");
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
running = 1;
|
running = 1;
|
||||||
if ((thread = SDL_CreateThreadInternal(EventUpdate, "PSPInputThread", 4096, NULL)) == NULL) {
|
if ((thread = SDL_CreateThreadInternal(EventUpdate, "PSPInputThread", 4096, NULL)) == NULL) {
|
||||||
SDL_SetError("Can't create input thread");
|
return SDL_SetError("Can't create input thread");
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void PSP_EventQuit(_THIS)
|
void PSP_EventQuit(_THIS)
|
||||||
|
|
|
@ -23,5 +23,7 @@
|
||||||
|
|
||||||
extern void PSP_InitOSKeymap(_THIS);
|
extern void PSP_InitOSKeymap(_THIS);
|
||||||
extern void PSP_PumpEvents(_THIS);
|
extern void PSP_PumpEvents(_THIS);
|
||||||
|
extern int PSP_EventInit(_THIS);
|
||||||
|
extern void PSP_EventQuit(_THIS);
|
||||||
|
|
||||||
/* end of SDL_pspevents_c.h ... */
|
/* end of SDL_pspevents_c.h ... */
|
||||||
|
|
|
@ -145,6 +145,10 @@ int PSP_VideoInit(_THIS)
|
||||||
SDL_VideoDisplay display;
|
SDL_VideoDisplay display;
|
||||||
SDL_DisplayMode current_mode;
|
SDL_DisplayMode current_mode;
|
||||||
|
|
||||||
|
if (PSP_EventInit(_this) == -1) {
|
||||||
|
return -1; /* error string would already be set */
|
||||||
|
}
|
||||||
|
|
||||||
SDL_zero(current_mode);
|
SDL_zero(current_mode);
|
||||||
|
|
||||||
current_mode.w = 480;
|
current_mode.w = 480;
|
||||||
|
@ -169,11 +173,13 @@ int PSP_VideoInit(_THIS)
|
||||||
SDL_AddDisplayMode(&display, ¤t_mode);
|
SDL_AddDisplayMode(&display, ¤t_mode);
|
||||||
|
|
||||||
SDL_AddVideoDisplay(&display, SDL_FALSE);
|
SDL_AddVideoDisplay(&display, SDL_FALSE);
|
||||||
return 1;
|
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void PSP_VideoQuit(_THIS)
|
void PSP_VideoQuit(_THIS)
|
||||||
{
|
{
|
||||||
|
PSP_EventQuit(_this);
|
||||||
}
|
}
|
||||||
|
|
||||||
void PSP_GetDisplayModes(_THIS, SDL_VideoDisplay *display)
|
void PSP_GetDisplayModes(_THIS, SDL_VideoDisplay *display)
|
||||||
|
|
Loading…
Reference in a new issue