Return-Path: X-Original-To: apmail-cordova-commits-archive@www.apache.org Delivered-To: apmail-cordova-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 13B4C1173B for ; Wed, 30 Jul 2014 19:06:21 +0000 (UTC) Received: (qmail 99795 invoked by uid 500); 30 Jul 2014 19:06:20 -0000 Delivered-To: apmail-cordova-commits-archive@cordova.apache.org Received: (qmail 99750 invoked by uid 500); 30 Jul 2014 19:06:20 -0000 Mailing-List: contact commits-help@cordova.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cordova.apache.org Delivered-To: mailing list commits@cordova.apache.org Received: (qmail 99569 invoked by uid 99); 30 Jul 2014 19:06:20 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 30 Jul 2014 19:06:20 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 1D63B99FD30; Wed, 30 Jul 2014 19:06:20 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: bhiggins@apache.org To: commits@cordova.apache.org Date: Wed, 30 Jul 2014 19:06:42 -0000 Message-Id: In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [25/38] git commit: BB10: Fix issues that getLocaleName return boolean instead of string value. BB10: Fix issues that getLocaleName return boolean instead of string value. * The reason is calling resultInJson(const char*) will be mapped to resultInJson(bool), instead of resultInJson(const std::string&). * Adding an explicit resultInJson(const char*) fixes this issue. Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-globalization/repo Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-globalization/commit/19eff2d9 Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-globalization/tree/19eff2d9 Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-globalization/diff/19eff2d9 Branch: refs/heads/lyon-g11n Commit: 19eff2d9a002b35ce2b3019d9cfe8b07c8a183c1 Parents: 8994da3 Author: Lianghui Chen Authored: Mon Jul 28 15:31:34 2014 -0400 Committer: Lianghui Chen Committed: Mon Jul 28 15:31:34 2014 -0400 ---------------------------------------------------------------------- src/blackberry10/native/src/globalization_ndk.cpp | 7 +++++++ 1 file changed, 7 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cordova-plugin-globalization/blob/19eff2d9/src/blackberry10/native/src/globalization_ndk.cpp ---------------------------------------------------------------------- diff --git a/src/blackberry10/native/src/globalization_ndk.cpp b/src/blackberry10/native/src/globalization_ndk.cpp index 835696d..7b70d95 100644 --- a/src/blackberry10/native/src/globalization_ndk.cpp +++ b/src/blackberry10/native/src/globalization_ndk.cpp @@ -60,6 +60,13 @@ std::string resultInJson(const std::string& value) return writer.write(root); } +// This is needed so resultInJson(const char*) will not be called into +// resultInJson(bool) implicitly. +static inline std::string resultInJson(const char* value) +{ + return resultInJson(std::string(value)); +} + std::string resultInJson(bool value) { Json::Value root;