diff options
| author | manuel <manuel@mausz.at> | 2018-08-30 00:42:04 +0200 |
|---|---|---|
| committer | manuel <manuel@mausz.at> | 2018-08-30 00:42:04 +0200 |
| commit | 2577b55681a97f3eec3fb0e3b5a4fb7f2cb18b8a (patch) | |
| tree | cc9e1f8ea69eebca8416677b2470a5b3f11a850e /xbmc/addons/kodi-addon-dev-kit/include/kodi/platform/android | |
| parent | b3d195f0188758a14875a5a2f270e4fd190a679f (diff) | |
| download | kodi-pvr-build-2577b55681a97f3eec3fb0e3b5a4fb7f2cb18b8a.tar.gz kodi-pvr-build-2577b55681a97f3eec3fb0e3b5a4fb7f2cb18b8a.tar.bz2 kodi-pvr-build-2577b55681a97f3eec3fb0e3b5a4fb7f2cb18b8a.zip | |
sync with upstream
Diffstat (limited to 'xbmc/addons/kodi-addon-dev-kit/include/kodi/platform/android')
| -rw-r--r-- | xbmc/addons/kodi-addon-dev-kit/include/kodi/platform/android/System.h | 44 |
1 files changed, 25 insertions, 19 deletions
diff --git a/xbmc/addons/kodi-addon-dev-kit/include/kodi/platform/android/System.h b/xbmc/addons/kodi-addon-dev-kit/include/kodi/platform/android/System.h index bee00ef..aad3a28 100644 --- a/xbmc/addons/kodi-addon-dev-kit/include/kodi/platform/android/System.h +++ b/xbmc/addons/kodi-addon-dev-kit/include/kodi/platform/android/System.h | |||
| @@ -1,24 +1,13 @@ | |||
| 1 | #pragma once | ||
| 2 | /* | 1 | /* |
| 3 | * Copyright (C) 2005-2018 Team Kodi | 2 | * Copyright (C) 2005-2018 Team Kodi |
| 4 | * http://kodi.tv | 3 | * This file is part of Kodi - https://kodi.tv |
| 5 | * | ||
| 6 | * This Program is free software; you can redistribute it and/or modify | ||
| 7 | * it under the terms of the GNU General Public License as published by | ||
| 8 | * the Free Software Foundation; either version 2, or (at your option) | ||
| 9 | * any later version. | ||
| 10 | * | ||
| 11 | * This Program is distributed in the hope that it will be useful, | ||
| 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 14 | * GNU General Public License for more details. | ||
| 15 | * | ||
| 16 | * You should have received a copy of the GNU General Public License | ||
| 17 | * along with KODI; see the file COPYING. If not, see | ||
| 18 | * <http://www.gnu.org/licenses/>. | ||
| 19 | * | 4 | * |
| 5 | * SPDX-License-Identifier: GPL-2.0-or-later | ||
| 6 | * See LICENSES/README.md for more information. | ||
| 20 | */ | 7 | */ |
| 21 | 8 | ||
| 9 | #pragma once | ||
| 10 | |||
| 22 | #include "../../AddonBase.h" | 11 | #include "../../AddonBase.h" |
| 23 | 12 | ||
| 24 | /* | 13 | /* |
| @@ -34,13 +23,14 @@ | |||
| 34 | */ | 23 | */ |
| 35 | 24 | ||
| 36 | static const char* INTERFACE_ANDROID_SYSTEM_NAME = "ANDROID_SYSTEM"; | 25 | static const char* INTERFACE_ANDROID_SYSTEM_NAME = "ANDROID_SYSTEM"; |
| 37 | static const char* INTERFACE_ANDROID_SYSTEM_VERSION = "1.0.0"; | 26 | static const char* INTERFACE_ANDROID_SYSTEM_VERSION = "1.0.1"; |
| 38 | static const char* INTERFACE_ANDROID_SYSTEM_VERSION_MIN = "1.0.0"; | 27 | static const char* INTERFACE_ANDROID_SYSTEM_VERSION_MIN = "1.0.1"; |
| 39 | 28 | ||
| 40 | struct AddonToKodiFuncTable_android_system | 29 | struct AddonToKodiFuncTable_android_system |
| 41 | { | 30 | { |
| 42 | void* (*get_jni_env)(); | 31 | void* (*get_jni_env)(); |
| 43 | int (*get_sdk_version)(); | 32 | int (*get_sdk_version)(); |
| 33 | const char *(*get_class_name)(); | ||
| 44 | }; | 34 | }; |
| 45 | 35 | ||
| 46 | //============================================================================== | 36 | //============================================================================== |
| @@ -99,6 +89,22 @@ namespace platform | |||
| 99 | return 0; | 89 | return 0; |
| 100 | } | 90 | } |
| 101 | 91 | ||
| 92 | //============================================================================ | ||
| 93 | /// | ||
| 94 | /// \ingroup cpp_kodi_platform | ||
| 95 | /// @brief request the android main class name e.g. org.xbmc.kodi. | ||
| 96 | /// | ||
| 97 | /// @param[in]: | ||
| 98 | /// @return package class name | ||
| 99 | /// | ||
| 100 | inline std::string GetClassName() | ||
| 101 | { | ||
| 102 | if (m_interface) | ||
| 103 | return m_interface->get_class_name(); | ||
| 104 | |||
| 105 | return std::string(); | ||
| 106 | } | ||
| 107 | |||
| 102 | private: | 108 | private: |
| 103 | AddonToKodiFuncTable_android_system *m_interface; | 109 | AddonToKodiFuncTable_android_system *m_interface; |
| 104 | }; | 110 | }; |
