Browse Source

backends: add XASH_MESSAGEBOX to specify messagebox platform implementation

pull/2/head
Alibek Omarov 5 years ago
parent
commit
7f1dd248c2
  1. 6
      common/backends.h
  2. 20
      common/defaults.h

6
common/backends.h

@ -47,4 +47,10 @@ GNU General Public License for more details. @@ -47,4 +47,10 @@ GNU General Public License for more details.
#define TIMER_LINUX 2
#define TIMER_WIN32 3
// messageboxes (XASH_MESSAGEBOX)
#define MSGBOX_STDERR 0
#define MSGBOX_SDL 1
#define MSGBOX_ANDROID 2
#define MSGBOX_WIN32 3
#endif /* BACKENDS_H */

20
common/defaults.h

@ -31,10 +31,18 @@ SETUP BACKENDS DEFINITIONS @@ -31,10 +31,18 @@ SETUP BACKENDS DEFINITIONS
#ifndef XASH_TIMER
#define XASH_TIMER TIMER_SDL
#endif
#ifndef XASH_MESSAGEBOX
#define XASH_MESSAGEBOX MSGBOX_SDL
#endif
#else
#ifndef XASH_TIMER
#define XASH_TIMER TIMER_LINUX
#endif
#ifndef XASH_MESSAGEBOX
#define XASH_MESSAGEBOX MSGBOX_STDERR
#endif
#endif
#ifdef XASH_SDL
@ -70,6 +78,10 @@ SETUP BACKENDS DEFINITIONS @@ -70,6 +78,10 @@ SETUP BACKENDS DEFINITIONS
#ifndef XASH_SOUND
#define XASH_SOUND SOUND_OPENSLES
#endif
#ifndef XASH_MESSAGEBOX
#define XASH_MESSAGEBOX MSGBOX_ANDROID
#endif
#endif // android case
#ifdef XASH_FBDEV
@ -88,6 +100,10 @@ SETUP BACKENDS DEFINITIONS @@ -88,6 +100,10 @@ SETUP BACKENDS DEFINITIONS
#ifndef XASH_SOUND
#define XASH_SOUND SOUND_ALSA
#endif
#ifndef XASH_MESSAGEBOX
#define XASH_MESSAGEBOX MSGBOX_STDERR
#endif
#define XASH_USE_EVDEV
#endif // android case
@ -130,6 +146,10 @@ SETUP BACKENDS DEFINITIONS @@ -130,6 +146,10 @@ SETUP BACKENDS DEFINITIONS
#define XASH_INPUT INPUT_NULL
#endif
#ifndef XASH_MESSAGEBOX
#define XASH_MESSAGEBOX MSGBOX_STDERR
#endif
/*
=========================================================================

Loading…
Cancel
Save