mirror of https://github.com/PCSX2/pcsx2.git
onepad:freebsd: Adjust ifdefs
This commit is contained in:
parent
a7ba779ba8
commit
f963fcfa66
|
@ -21,11 +21,7 @@
|
||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
#include <string.h> // for memset
|
#include <string.h> // for memset
|
||||||
#ifdef __linux__
|
|
||||||
#define MAX_KEYS 24
|
#define MAX_KEYS 24
|
||||||
#else
|
|
||||||
#define MAX_KEYS 20
|
|
||||||
#endif
|
|
||||||
|
|
||||||
enum KeyType
|
enum KeyType
|
||||||
{
|
{
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#include <gdk/gdkkeysyms.h>
|
#include <gdk/gdkkeysyms.h>
|
||||||
#include "keyboard.h"
|
#include "keyboard.h"
|
||||||
|
|
||||||
#ifndef __linux__
|
#ifdef _WIN32
|
||||||
char* KeysymToChar(int keysym)
|
char* KeysymToChar(int keysym)
|
||||||
{
|
{
|
||||||
LPWORD temp;
|
LPWORD temp;
|
||||||
|
@ -40,7 +40,7 @@ char* KeysymToChar(int keysym)
|
||||||
|
|
||||||
void SetAutoRepeat(bool autorep)
|
void SetAutoRepeat(bool autorep)
|
||||||
{
|
{
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
if (toggleAutoRepeat)
|
if (toggleAutoRepeat)
|
||||||
{
|
{
|
||||||
if (autorep)
|
if (autorep)
|
||||||
|
@ -51,7 +51,7 @@ void SetAutoRepeat(bool autorep)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
static bool s_grab_input = false;
|
static bool s_grab_input = false;
|
||||||
static bool s_Shift = false;
|
static bool s_Shift = false;
|
||||||
static unsigned int s_previous_mouse_x = 0;
|
static unsigned int s_previous_mouse_x = 0;
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
|
|
||||||
#include "onepad.h"
|
#include "onepad.h"
|
||||||
|
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
|
|
||||||
#include "Linux/linux.h"
|
#include "Linux/linux.h"
|
||||||
|
|
||||||
|
|
|
@ -263,7 +263,7 @@ EXPORT_C_(s32) PADopen(void *pDsp)
|
||||||
pthread_spin_init(&mutex_KeyEvent, PTHREAD_PROCESS_PRIVATE);
|
pthread_spin_init(&mutex_KeyEvent, PTHREAD_PROCESS_PRIVATE);
|
||||||
mutex_WasInit = true;
|
mutex_WasInit = true;
|
||||||
|
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
GamePad::EnumerateGamePads(s_vgamePad);
|
GamePad::EnumerateGamePads(s_vgamePad);
|
||||||
#endif
|
#endif
|
||||||
return _PADopen(pDsp);
|
return _PADopen(pDsp);
|
||||||
|
@ -595,7 +595,7 @@ EXPORT_C_(keyEvent*) PADkeyEvent()
|
||||||
return &s_event;
|
return &s_event;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
EXPORT_C_(void) PADWriteEvent(keyEvent &evt)
|
EXPORT_C_(void) PADWriteEvent(keyEvent &evt)
|
||||||
{
|
{
|
||||||
// This function call be called before PADopen. Therefore we cann't
|
// This function call be called before PADopen. Therefore we cann't
|
||||||
|
|
|
@ -49,7 +49,7 @@ using namespace std;
|
||||||
#define PADdefs
|
#define PADdefs
|
||||||
#include "PS2Edefs.h"
|
#include "PS2Edefs.h"
|
||||||
|
|
||||||
#ifdef __linux__
|
#if defined(__unix__)
|
||||||
#include "GamePad.h"
|
#include "GamePad.h"
|
||||||
#endif
|
#endif
|
||||||
#include "bitwise.h"
|
#include "bitwise.h"
|
||||||
|
|
Loading…
Reference in New Issue