Said before
Sencha phonegap Init com.pushsoft.myapp MyApp
After the packaged program install package APK name is "myapp.apk", the program name displayed on the phone desktop (the text below the icon) is also "MyApp"
If you want to change to a different name, change the Myapp\config.xml file, and change the top "<name>MyApp</name>" in the middle of the MyApp to the required name. Note that the assumption of XML content in Chinese, to be changed to UTF-8 encoding, note that the text file encoding, not the top "<?xml version= '1.0 ' encoding= ' utf-8 '"?>. It is recommended to change the encoding of the text file with notepad++.
The problem here is that if you change the name to a full Chinese, such as "My Program", it will cause the Sencha app build native to fail (PhoneGap local build Android is also a failure), for example:
Figure one: Project name garbled
Figure two: Compilation failure
Figure three: Java files in the generated Android project do not have a file name
Figure IV: The contents of the Java file with figure two, no class name causes compilation to fail
The reason is that the Java file class name comes from a file in the CONFIG. "<name> My program </name>" middle name, Cordova or PHONEGAP support for Chinese is not very good, resulting in such a situation.
The workarounds are as follows:
Open C:\Users\username\.cordova\lib\android\cordova\3.4.0\bin\lib\create.js and find the following red box content
Change to look like this:
The purpose of this amendment is to assume that the name in config. cordovaexample is in English, use the name of the English language, and assume that the name is changed to full Chinese.
After the packaged program installation package APK name is "cordovaexampleapk", the program name displayed on the phone desktop (the text below the icon) is "my program"
Suppose you think that the apk name "cordovaexample.apk" is not very good, but want to change the file name, for example, want to put the package name (such as "Com.pushsoft.myapp") as the last part of the file name ( such as "MyApp"), Can change this: