| 1 | |
| 2 | /** |
| 3 | * |
| 4 | * @file android.h |
| 5 | * |
| 6 | * Part of the OpenJazz project |
| 7 | * |
| 8 | * @par Licence: |
| 9 | * Copyright (c) 2015-2026 Carsten Teibes |
| 10 | * |
| 11 | * OpenJazz is distributed under the terms of |
| 12 | * the GNU General Public License, version 2.0 |
| 13 | * |
| 14 | */ |
| 15 | |
| 16 | |
| 17 | #ifndef _ANDROID_H |
| 18 | #define _ANDROID_Hcxx . . $ `src/platforms/android.h:18:9`! |
| 19 | |
| 20 | #include "platform_interface.h"cxx . . $ `<file>/src/platforms/platform_interface.h`/ |
| 21 | |
| 22 | #ifdef __ANDROID__ |
| 23 | |
| 24 | /* Platform uses SDL2 */ |
| 25 | |
| 26 | // video config |
| 27 | |
| 28 | #define DEFAULT_SCREEN_WIDTH 640 |
| 29 | #define DEFAULT_SCREEN_HEIGHT 480 |
| 30 | //#define FULLSCREEN_ONLY |
| 31 | |
| 32 | // keyboard config |
| 33 | |
| 34 | #define DEFAULT_KEY_ESCAPE SDLK_AC_BACK /* back button */ |
| 35 | |
| 36 | // controller config |
| 37 | |
| 38 | #define DEFAULT_BUTTON_JUMP (2) |
| 39 | #define DEFAULT_BUTTON_SWIM (2) |
| 40 | #define DEFAULT_BUTTON_FIRE (4) |
| 41 | #define DEFAULT_BUTTON_CHANGE (3) |
| 42 | #define DEFAULT_BUTTON_ENTER (1) |
| 43 | #define DEFAULT_BUTTON_ESCAPE (6) |
| 44 | #define DEFAULT_BUTTON_STATS (5) |
| 45 | #define DEFAULT_BUTTON_PAUSE (7) |
| 46 | |
| 47 | class AndroidPlatform final : public IPlatform { |
| 48 | public: |
| 49 | void AddGamePaths() override; |
| 50 | }; |
| 51 | |
| 52 | #endif |
| 53 | |
| 54 | #endif |