diff options
author | ExMix <rahuba.youri@mapswithme.com> | 2014-10-24 16:35:46 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 02:31:32 +0300 |
commit | 7d9d3633c7a3ec4fa3ac1170488e8aa63899b9c1 (patch) | |
tree | 8c1a6d48f22d28243dbea7de560f5f1658952485 /android/jni/com/mapswithme/country/CountryTree.cpp | |
parent | 338c645218fd84ebc24acf66eb55b6ecf48e97ce (diff) |
review fixes
Diffstat (limited to 'android/jni/com/mapswithme/country/CountryTree.cpp')
-rw-r--r-- | android/jni/com/mapswithme/country/CountryTree.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/android/jni/com/mapswithme/country/CountryTree.cpp b/android/jni/com/mapswithme/country/CountryTree.cpp index bbd6948dca..2e932c5c8c 100644 --- a/android/jni/com/mapswithme/country/CountryTree.cpp +++ b/android/jni/com/mapswithme/country/CountryTree.cpp @@ -50,10 +50,10 @@ extern "C" { CountryTree & tree = GetTree(); int corePosition = static_cast<int>(position); - jboolean isLeaf = tree.IsLeaf(corePosition) ? JNI_TRUE : JNI_FALSE; + bool const isLeaf = tree.IsLeaf(corePosition); jstring name = jni::ToJavaString(env, tree.GetChildName(corePosition)); - jint status = isLeaf == JNI_TRUE ? static_cast<jint>(tree.GetLeafStatus(corePosition)) : 0; - jint options = isLeaf == JNI_TRUE ? static_cast<jint>(tree.GetLeafOptions(corePosition)) : 0; + jint status = isLeaf ? static_cast<jint>(tree.GetLeafStatus(corePosition)) : 0; + jint options = isLeaf ? static_cast<jint>(tree.GetLeafOptions(corePosition)) : 0; jclass createClass = env->FindClass("com/mapswithme/country/CountryItem"); ASSERT(createClass, ()); @@ -62,7 +62,7 @@ extern "C" ASSERT(methodId, ()); return env->NewObject(createClass, createMethodId, - name, status, options, !isLeaf); + name, status, options, (!isLeaf) == true ? JNI_TRUE : JNI_FALSE); } JNIEXPORT void JNICALL @@ -112,7 +112,7 @@ extern "C" { CountryTree & tree = GetTree(); int pos = static_cast<int>(position); - int local = (isLocal == JNI_TRUE) ? true : false; + bool const local = (isLocal == JNI_TRUE) ? true : false; TMapOptions opt = ToOptions(options); if (options == -1 || local) |