Skip to content
This repository has been archived by the owner on Jan 9, 2023. It is now read-only.

CB-8515 Support DefaultLanguage selection for Windows #59

Closed
wants to merge 1 commit into from
Closed

CB-8515 Support DefaultLanguage selection for Windows #59

wants to merge 1 commit into from

Conversation

muratsu
Copy link
Contributor

@muratsu muratsu commented Feb 20, 2015

Cordova should set the appropriate project file attributes for Windows 8.0, 8.1, and Windows Phone 8.1 using the W3C widget spec "defaultlocale" attribute.

Related JIRA: https://issues.apache.org/jira/browse/CB-8515

function updatejsprojFile(config, jsProjFilePath) {
var defaultLocale = config.defaultLocale();

if (defaultLocale) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should remove or set to default DefaultLanguage in case there is no config.defaultLocale().

@muratsu
Copy link
Contributor Author

muratsu commented Feb 20, 2015

if no locale is not found it uses the current default language which is en-us. Since that is already hardcoded in proj files I'm not re-setting it. removing might have some side effects.

@sgrebnov
Copy link
Member

I meant if you changed locale in config.xml and then removed this settings it will continue pointing to the wrong previously used locale, not the default one.

@sgrebnov
Copy link
Member

May be just use something like this
var defaultLocale = config.defaultLocale() || 'en-us';

@sgrebnov
Copy link
Member

But this is minor, so I'm +1 merging this.

@muratsu
Copy link
Contributor Author

muratsu commented Feb 20, 2015

I'll fix the default locale to en-US. When a defaultlocale is not present we should set it to en-US. Good catch!

@nikhilkh
Copy link
Contributor

This looks good! @sgrebnov Can you please help merge this one? It will be good to have this in the next cordova-windows release.

@asfgit asfgit closed this in e25bc2a Feb 21, 2015
@anna-sunberg
Copy link

This change is still not reflected in documentation in https://cordova.apache.org/docs/en/latest/config_ref/ (defaultlocale is shown as iOS-only)

janpio added a commit to apache/cordova-docs that referenced this pull request Jan 22, 2018
@janpio
Copy link
Member

janpio commented Jan 22, 2018

Documentation change is PRd, please have a look at apache/cordova-docs#782

janpio added a commit to apache/cordova-docs that referenced this pull request Feb 23, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants