mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-10-08 11:33:28 +00:00
initialize values correctly for older compilers
This commit is contained in:
parent
af2e18dcc3
commit
0d50f78705
@ -10,7 +10,7 @@ extern "C" {
|
||||
}
|
||||
}
|
||||
|
||||
SDLJoystick::SDLJoystick(bool init_SDL ){
|
||||
SDLJoystick::SDLJoystick(bool init_SDL ): running(true),joy(NULL),thread(NULL){
|
||||
if (init_SDL)
|
||||
{
|
||||
SDL_Init(SDL_INIT_JOYSTICK | SDL_INIT_VIDEO
|
||||
@ -119,7 +119,6 @@ void SDLJoystick::ProcessInput(SDL_Event &event){
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void SDLJoystick::runLoop(){
|
||||
while (running){
|
||||
SDL_Event evt;
|
||||
@ -128,4 +127,4 @@ void SDLJoystick::runLoop(){
|
||||
ProcessInput(evt);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,19 +1,18 @@
|
||||
//#ifdef _WIN32
|
||||
//#include "SDL/SDL.h"
|
||||
//#include "SDL/SDL_joystick.h"
|
||||
//#include "SDL/SDL_thread.h"
|
||||
//#else
|
||||
#pragma once
|
||||
|
||||
#ifdef _WIN32
|
||||
#include "SDL/SDL.h"
|
||||
#include "SDL/SDL_joystick.h"
|
||||
#include "SDL/SDL_thread.h"
|
||||
#else
|
||||
#include "SDL.h"
|
||||
#include "SDL_joystick.h"
|
||||
#include "SDL_thread.h"
|
||||
//#endif
|
||||
#endif
|
||||
|
||||
#include "input/input_state.h"
|
||||
#include "input/keycodes.h"
|
||||
#include "net/resolve.h"
|
||||
#include "base/NKCodeFromSDL.h"
|
||||
#include "base/NativeApp.h"
|
||||
|
||||
extern "C" {
|
||||
@ -90,8 +89,8 @@ private:
|
||||
std::map<int, int> SDLJoyButtonMap;
|
||||
std::map<int, int> SDLJoyAxisMap;
|
||||
|
||||
SDL_Joystick *joy = NULL;
|
||||
SDL_Thread *thread = NULL;
|
||||
bool running = true;
|
||||
SDL_Joystick *joy ;
|
||||
SDL_Thread *thread ;
|
||||
bool running ;
|
||||
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user