forked from organicmaps/organicmaps
[android] Fixed getting displayed categories JNI method
This commit is contained in:
parent
fc1173827d
commit
cfd1d3cad5
1 changed files with 7 additions and 3 deletions
|
@ -1,12 +1,16 @@
|
|||
#include "search/displayed_categories.hpp"
|
||||
#include "com/mapswithme/maps/Framework.hpp"
|
||||
#include "com/mapswithme/core/jni_helper.hpp"
|
||||
|
||||
#include "../core/jni_helper.hpp"
|
||||
#include "search/displayed_categories.hpp"
|
||||
|
||||
extern "C"
|
||||
{
|
||||
JNIEXPORT jobjectArray JNICALL
|
||||
Java_com_mapswithme_maps_search_DisplayedCategories_nativeGetKeys(JNIEnv * env, jclass clazz)
|
||||
{
|
||||
return jni::ToJavaStringArray(env, search::DisplayedCategories::GetKeys());
|
||||
::Framework * fr = g_framework->NativeFramework();
|
||||
ASSERT(fr, ());
|
||||
search::DisplayedCategories categories = fr->GetDisplayedCategories();
|
||||
return jni::ToJavaStringArray(env, categories.GetKeys());
|
||||
}
|
||||
} // extern "C"
|
||||
|
|
Loading…
Add table
Reference in a new issue