[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-07-14 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14061099#comment-14061099
 ] 

ASF GitHub Bot commented on CB-4602:


Github user asfgit closed the pull request at:

https://github.com/apache/cordova-plugin-globalization/pull/15


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-07-14 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14061097#comment-14061097
 ] 

ASF subversion and git services commented on CB-4602:
-

Commit bbed836ec5368a135036765eb801c0ead00426d9 in 
cordova-plugin-globalization's branch refs/heads/master from [~eweiter]
[ 
https://git-wip-us.apache.org/repos/asf?p=cordova-plugin-globalization.git;h=bbed836
 ]

CB-4602 ios: Use normalized values for getPreferredLanguage.

close #15


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-07-03 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14051443#comment-14051443
 ] 

ASF GitHub Bot commented on CB-4602:


Github user eweit closed the pull request at:

https://github.com/apache/cordova-plugin-globalization/pull/14


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-07-03 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14051560#comment-14051560
 ] 

ASF GitHub Bot commented on CB-4602:


GitHub user eweit opened a pull request:

https://github.com/apache/cordova-plugin-globalization/pull/15

CB-4602 Changed CDVGlobalization.m so that the return string of getPrefe...

...rredLanguage returns a string that is the same as other devices, such as 
Android.  IOS was displaying simple language tags for certain languages, like 
have US as the locale and English as the language, getPreferredLanguage would 
return en.  Changed so it returns en-US and similiar for other languages.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/eweit/cordova-plugin-globalization CB-4602-2

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cordova-plugin-globalization/pull/15.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #15


commit b5d8e3ff801d48f5b9dfe1c30eb096992d868e3c
Author: Eric Weiterman ewei...@us.ibm.com
Date:   2014-07-03T15:10:50Z

CB-4602 Changed CDVGlobalization.m so that the return string of 
getPreferredLanguage returns a string that is the same as other devices, such 
as Android.  IOS was displaying simple language tags for certain languages, 
like have US as the locale and English as the language, getPreferredLanguage 
would return en.  Changed so it returns en-US and similiar for other languages.




 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-06-27 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14046232#comment-14046232
 ] 

ASF subversion and git services commented on CB-4602:
-

Commit b7d0862cf48371959c7413c4244a6822acb0d0a5 in 
cordova-plugin-globalization's branch refs/heads/master from [~eweit.ibm]
[ 
https://git-wip-us.apache.org/repos/asf?p=cordova-plugin-globalization.git;h=b7d0862
 ]

CB-4602 geolocation.getPreferredLanguage and geolocation.getLocaleName now 
return strings with hypen (-) to stay compliant with current standards


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-06-24 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14042180#comment-14042180
 ] 

ASF GitHub Bot commented on CB-4602:


GitHub user eweit opened a pull request:

https://github.com/apache/cordova-plugin-globalization/pull/14

CB-4602 geolocation.getPreferredLanguage and geolocation.getLocaleName n...

BCP-47 compliance for getLocaleName, getPreferredLanguage.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/eweit/cordova-plugin-globalization CB-4602

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cordova-plugin-globalization/pull/14.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #14


commit 08f50cd67f71d61e09a826e9e1fd18b459bde764
Author: Eric Weiterman ewei...@us.ibm.com
Date:   2014-06-23T21:10:49Z

CB-4602 geolocation.getPreferredLanguage and geolocation.getLocaleName now 
return strings with hypen (-) to stay compliant with current standards




 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-06-16 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14032579#comment-14032579
 ] 

ASF GitHub Bot commented on CB-4602:


Github user svkirans closed the pull request at:

https://github.com/apache/cordova-plugin-globalization/pull/8


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-05-23 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14006850#comment-14006850
 ] 

ASF subversion and git services commented on CB-4602:
-

Commit 86bd57c39bee21116ce6ced42254f34be602c9cd in 
cordova-plugin-globalization's branch refs/heads/master from [~stacic]
[ 
https://git-wip-us.apache.org/repos/asf?p=cordova-plugin-globalization.git;h=86bd57c
 ]

CB-4602 CB-6490 CB-4822 WP Globalization

BCP-47 compliance for getLocaleName, getPreferredLanguage.


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-05-23 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14006854#comment-14006854
 ] 

ASF subversion and git services commented on CB-4602:
-

Commit be9b83b1900dea88258d9aa23bd398f41b0ba198 in 
cordova-plugin-globalization's branch refs/heads/master from [~purplecabbage]
[ 
https://git-wip-us.apache.org/repos/asf?p=cordova-plugin-globalization.git;h=be9b83b
 ]

Merge branch 'CB-4602wp' of 
https://github.com/stacic/cordova-plugin-globalization


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-05-23 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14006853#comment-14006853
 ] 

ASF subversion and git services commented on CB-4602:
-

Commit 2ad8451e763896360fc4212fb0051039390e3baf in 
cordova-plugin-globalization's branch refs/heads/master from [~stacic]
[ 
https://git-wip-us.apache.org/repos/asf?p=cordova-plugin-globalization.git;h=2ad8451
 ]

CB-4602 Added clarification to docs


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-04-29 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13984226#comment-13984226
 ] 

ASF GitHub Bot commented on CB-4602:


Github user mbillau closed the pull request at:

https://github.com/apache/cordova-plugin-globalization/pull/9


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Martin Gonzalez
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-04-29 Thread Mike Billau (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13984437#comment-13984437
 ] 

Mike Billau commented on CB-4602:
-

I made some changes to the implementation above. I found out that Java 7 
implements a method called Locale#toLanguageTag(), so I followed that as much 
as possible. I pushed up a new branch to the globalization plugin because there 
are a few other changes that we are in the process of making, so we will just 
commit to that branch and then bump the major version once. 

https://github.com/apache/cordova-plugin-globalization/commit/baea8a295daebdb6cc2bfcdcb612d6c988a8e08a

Somehow git reverted some of the previous changes (changing new Long() to 
Long.valueOf), so I'll figure out why and fix that.

 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-04-29 Thread Mike Billau (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13984618#comment-13984618
 ] 

Mike Billau commented on CB-4602:
-

I'm not sure what the difference between getPreferredLanguage() and 
getLocaleName() is. Should one return the BCP-47 language tag (en-US)  while 
the other return the actual text representation of the language (English)?

Based on some older docs: 
http://cordova.apache.org/docs/en/3.1.0/cordova_globalization_globalization.md.html#globalization.getPreferredLanguage,
 it seems like getPreferredLanguage should return the textual representation 
while getLocaleName should return the language tag.

That means I should revert the changes to getPreferredLanguage and make them to 
getLocaleName() instead. This also means that WP8 and iOS will have to change 
their implementation of getPreferredLanguage since they both return tags and 
not string representations.

 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Mike Billau
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-04-28 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13983409#comment-13983409
 ] 

ASF GitHub Bot commented on CB-4602:


GitHub user mbillau opened a pull request:

https://github.com/apache/cordova-plugin-globalization/pull/9

Android should return BCP47 tag, not localized string

For https://issues.apache.org/jira/browse/CB-4602
I still want to test the consistency with iOS.
Return the Locale.getDefault().toString() which according to the Android 
docs [1], contains a two-letter lowercase ISO language code (ISO 639-1) 
followed by an underscore, followed by the two-letter uppercase country code 
(ISO 3166-1). As best I can tell, these two specs (and some more) are what make 
up BCP 47, therefore we should be able to assume that this will always return 
BCP 47 compliant language tags. 

I did notice that sometimes toString() will leave out country or language 
codes if they don't exist. For example, if you set locale to be Locale.CHINESE, 
then you'll get back zh - no country code. I'm not sure if this is BCP 47, or 
if there is anything we can do about it.

Finally, since this changes an API, would we have to do a major bump to the 
plugin version number? I thought about deprecating the old code and/or creating 
a new API method but chose against that since this is a bug fix and not a 
feature request. I think the version number should be bumped though...

[1]  http://developer.android.com/reference/java/util/Locale.html




You can merge this pull request into a Git repository by running:

$ git pull https://github.com/mbillau/cordova-plugin-globalization CB-4602

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cordova-plugin-globalization/pull/9.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #9


commit 64734dbd067330a8a787724a8df0a73325c96276
Author: mbillau mike.bil...@gmail.com
Date:   2014-04-28T19:02:39Z

Android should return BCP47 tag, not localized string




 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Martin Gonzalez
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-04-24 Thread Mike Billau (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13979803#comment-13979803
 ] 

Mike Billau commented on CB-4602:
-

According to http://docs.oracle.com/javase/7/docs/api/java/util/Locale.html, 
the Locale object implements identifiers interchangeable with BCP 47. This 
means that for Android, we can simply return `Locale.getDefault()` and it 
should be BCP47 compliant.  I tried this:

locale = SIMPLIFIED_CHINESE, getDefault = zh_CN
locale = CHINESE, getDefault = zh
locale = TAIWAN, getDefault = zh_TW
locale= English, getDefault = en_US

These results match up with what [~pdardailler] mentioned above, execpt for the 
underscore instead of the dash. I'm not sure why CHINESE locale only returned 
zh. There also might be issues since according to 
http://developer.android.com/reference/java/util/Locale.html, Java uses 
several deprecated two-letter codes. The Hebrew (he) language code is 
rewritten as iw, Indonesian (id) as in, and Yiddish (yi) as ji. This 
rewriting happens even if you construct your own Locale object, not just for 
instances returned by the various lookup methods. 

Finally, since this is changing the return value of an API, we should probably 
create a new method, like getPreferredLanguageCode() or something, instead of 
just changing getPreferredLanguage(). 

 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Martin Gonzalez
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-04-22 Thread Pascale Dardailler (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13977106#comment-13977106
 ] 

Pascale Dardailler commented on CB-4602:


The proposed implementation will not improve the consistency if not all 
platforms agree on the same implementation. Locale#getISO3Language() in Android 
SDK will return eng for English, where most people will expect ISO alpha-2 
language code (ISO639-1) en. In addition to this, language preference may 
need to distinguish regional dialects (for example, American English vs British 
English, Brazilian Portuguese vs Iberian Portuguese...)

It would be better to have each platform return a valid BCP 47 Language Tag 
(see http://tools.ietf.org/html/bcp47). This will mean that implementation 
could return zh-Hant and zh-Hans to differentiate Traditional from 
Simplified Chinese, pt-BR and pt-PT to differentiate Brazilian Portuguese 
from Iberian Portuguese and same for any language that needs to be 
differentiated from the base language. It seems that iOS implementation is the 
correct one. 
It is recommended that an implementation of this function distinguish regional 
dialects or written scripts by adding country subtag or script subtag if 
necessary. For example, to distinguish between Portuguese dialects, pt-BR 
(Brazilian Portuguese) and pt-PT (Iberian Portuguese) are commonly used. For 
Chinese, an implementation may use zh-Hans for Chinese contents written in 
Simplified Chinese characters, and zh-Hant for Chinese contents written in 
Traditional Chinese characters. (Some others may use zh-CN to specify Chinese 
used in China, which implies the contents is written in Simplified Chinese 
characters, and zh-TW to specify Chinese used in Taiwan, which implies the 
contents is written in Traditional Chinese. Such implementations are also 
acceptable.)

The documentation will need to be changed, to simply state that the API returns 
a valid BCP 47 Language Tag.

WindowsPhone8 should use CultureInfo.CurrentUICulture.Name, which should be 
also BCP 47 language tag expression of preferred language setting. 

Android should not return the localized language name.


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Joe Bowser
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-04-08 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13963280#comment-13963280
 ] 

ASF GitHub Bot commented on CB-4602:


GitHub user svkirans opened a pull request:

https://github.com/apache/cordova-plugin-globalization/pull/8

The  ISO 639-2 code is returned for the default language. Probable fix f...

The  ISO 639-2 code is returned for the default language. Probable fix for 
CB-4602.

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/svkirans/cordova-plugin-globalization master

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/cordova-plugin-globalization/pull/8.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #8


commit bdf8fb23797fb2acbb5f91cc017c5e365771ea7d
Author: Kiran svkir...@gmail.com
Date:   2014-04-08T18:17:53Z

The  ISO 639-2 code is returned for the default language. Probable fix for 
CB-4602.




 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Joe Bowser
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (CB-4602) getPreferredLanguage platform inconsistencies

2014-01-02 Thread Justin Wark (JIRA)

[ 
https://issues.apache.org/jira/browse/CB-4602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13860928#comment-13860928
 ] 

Justin Wark commented on CB-4602:
-

Hi, I am having the same problem using Cordova 3.3.1.
The documentation for 'getPreferredLanguage' states: Returns the language 
identifier string however the example is: When the browser is set to the 
en\_US locale, this should display a popup dialog with the text language: 
English.
see: 
http://cordova.apache.org/docs/en/3.3.0/cordova_globalization_globalization.md.html#globalization.getPreferredLanguage

When i test it on Android I get: English
On iOS I get: en

I personally think the code (e.g. 'en') is more useful however I don't really 
mind either way.  Can the documentation and implementations please be made 
consistent?


 getPreferredLanguage platform inconsistencies
 -

 Key: CB-4602
 URL: https://issues.apache.org/jira/browse/CB-4602
 Project: Apache Cordova
  Issue Type: Bug
  Components: Android, Plugin Globalization
Affects Versions: 2.6.0, 3.0.0
 Environment: Android
Reporter: Jon Whitlock
Assignee: Joe Bowser
Priority: Minor

 In;
 https://github.com/apache/cordova-docs/blob/master/docs/en/edge/cordova/globalization/globalization.getPreferredLanguage.md
 Returns the language identifier string to the successCallback with a 
 properties object as a parameter. That object should have a value property 
 with a String value.
 navigator.globalization.getPreferredLanguage(
function (language) {alert('language: ' + language.value + '\n');},
function () {alert('Error getting language\n');}
 );
 On Android the function doesn't seem to return an identifier as such, it 
 returns *a string describing the language localised to that language*, e.g. 
 English for English or 中文 for Japanese. Naturally this is less than ideal 
 for subsequent string operations, furthermore on that page Windows Phone 8 
 Quirks - Returns the ISO 639-1 two-letter code for the current language 
 which is an identifier, and also what I would expect (or an ISO 639-2 code, 
 as per http://www.loc.gov/standards/iso639-2/php/code_list.php)
 Android seems to support 639-2 
 http://developer.android.com/reference/java/util/Locale.html#getISO3Language()
 I have no idea what it returns on other platforms, but to keep client code 
 consistent I guess it would good if this could be normalised in the API.
 Have tested this on v3.0 and 2.6, is the same.
 As an aside, the locale is not really what I want here, as the user may be in 
 the US but have Japanese as their preferred language.
 Thanks,
 jon
 (first go at using Jira, apols if I got something wrong!)



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)