- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I found the latest iOS version available to target is 9.2. Could I change it to 10.2 in case I create a plug-in which require target iOS 10.2 at least ?
P.S. XDK version 3900 on iMac
- Tags:
- HTML5
- Intel® XDK
Link Copied
- « Previous
-
- 1
- 2
- Next »
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Okay, I believe I understand now. You need to modify the plugin to include your "locales/android/values-en/strings.xml" (for example) within the plugin folder, which changes as a function of the specific app.
I see a few ways to possibly deal with this with PhoneGap Build (there may be others), shown in order of most likely to work to least likely to work:
- create a unique version of your plugin for each application and reference it via a GitHub repo, not via NPM
- create a unique version of your plugin for each application and reference it via NPM, for example:
localize-app-name-my-app1
localize-app-name-my-app2
etc. - place the language-specific files into your app, inside the www folder, and reference them from your plugin.xml file using something like:
../../www/locales/android/values-en/strings.xml
this would need to be tested, because it depends on a few things being done in the right order, but it might work - use a symbolic link (to do something like above) to reference a file that is outside of the plugins folder (again, like above, this depends on a few assumptions about how PhoneGap Build assembles the project that gets built, as well as depends on the symbolic link getting translated correctly in the process, which can be a big problem).
I have not tested these, but the first two should definitely work. In those cases you are essentially going to create a plugin that is specific to each app you publish.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks for your advice.
I tried to use PhoneGap Cloud Build and it works after make our 'Private' plugin public in npm. Although it is not customized to our target version. But it is good enough to testing the build system. However, I got these issues:
- for ipa, the splash screen won't hide (it works fine for XDK cloud build), but after stop the app and open it again, it shows my 1st screen in the app
- although splash screen will hide in apk case, but it is much longer that expected (now it shows for several seconds where for apk generated from XDK cloud build, it is less then 0.5s)
- don't know why app (ipa/apk) both show the app name not defined in our XDK project build settings: App Name, so I would like to know where XDK get the app name and set in config.xml's <name> </name>
P.S.
extract from config.xml:
<platform name="ios"> <!-- prevent screen scrolling for the whole app --> <preference name="DisallowOverscroll" value="true"/> <!-- below requires the splash screen plugin --> <!-- docs: https://github.com/apache/cordova-plugin-splashscreen --> <preference name="AutoHideSplashScreen" value="false"/> <preference name="SplashScreenDelay" value="1000"/> <preference name="FadeSplashScreen" value="false"/> <preference name="ShowSplashScreenSpinner" value="false"/> <!-- below requires the status bar plugin --> <!-- docs: https://github.com/apache/cordova-plugin-statusbar --> <!-- see http://devgirl.org/2014/07/31/phonegap-developers-guid --> <!-- status bar overlay for iOS only, if true, navbar height need to add 20px and override original by define in app.css --> <preference name="StatusBarOverlaysWebView" value="true"/> <!-- haven't try other StatusBarStyle to make the bar text color in black, now it is white --> <preference name="StatusBarBackgroundColor" value="#aa3e50"/> <preference name="StatusBarStyle" value="lightcontent"/> </platform> <platform name="android"> <!-- below requires the splash screen plugin --> <!-- docs: https://github.com/apache/cordova-plugin-splashscreen --> <preference name="StatusBarBackgroundColor" value="#aa3e50"/> <preference name="AutoHideSplashScreen" value="false"/> <preference name="FadeSplashScreen" value="false"/> <preference name="ShowSplashScreenSpinner" value="false"/> <preference name="SplashMaintainAspectRatio" value="false"/> </platform>
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Arthur T. wrote:
- for ipa, the splash screen won't hide (it works fine for XDK cloud build), but after stop the app and open it again, it shows my 1st screen in the app
- although splash screen will hide in apk case, but it is much longer that expected (now it shows for several seconds where for apk generated from XDK cloud build, it is less then 0.5s)
I cannot explain why the delay for the splash screen is inconsistent, but, based on the config.xml snippet you provided, the splash screen will not disappear automatically because the "AutoHideSplashScreen" preference is set to "false" (see the docs here https://github.com/apache/cordova-plugin-splashscreen#preferences).
Based on this info, my guess is that the code that makes the call to hide the splash screen is not getting called (in the IPA case) or is being delayed for some reason (in the APK case). Here is how it is done with the "hello cordova" sample > https://github.com/gomobile/sample-hello-cordova/blob/master/www/js/init-app.js#L193 < You might want to make a project from the "hello cordova" sample and build it with PhoneGap Build to see if you get the same results as your app (that it is delayed heavily or doesn't happen). If the "hello cordova" sample works correctly (make sure to add the "false" setting in the "hello cordova" project for the AutoHideSplashScreen preferences to make it equivalent) you can assume that it is probably related to how you implement the call to hide the splash screen. If the "hello cordova" sample does not work, we can use that to debug the issue, as it will likely be an easier set of code to figure out what is going wrong.
Arthur T. wrote:
- don't know why app (ipa/apk) both show the app name not defined in our XDK project build settings: App Name, so I would like to know where XDK get the app name and set in config.xml's <name> </name>
The name of the APK and IPA, as it appears on the device when it is installed (which is what I assume you mean), is defined by the <name> tag inside the config.xml file that is exported by the Cordova Build Package tool. See this Cordova doc > https://cordova.apache.org/docs/en/latest/config_ref/#name < for reference. That name should match what's stored in the "App Name" field in the Build Settings. Note that if you have it set to different values in each of the Build Settings screens (Android does not match iOS which does not match Windows), you may not get the one you expected. I believe the tool is configured to favor the Android name over the others, if multiple targets are selected during the export.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- no, it is bug of XDK Cordova Build Package as it used project name (the ? from ?.xdk, ?.xdke) instead of get from App Name in build settings to set <name></name> in config.xml
- could I use variable and value pair of plugin for the purpose of customization after include the plugin?
P.S.
I will try on making "AutoHideSplashScreen" preference is set to "true" and see the effect
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
fyi: I update config.xml AutoHideSplashScreen to true and now iOS will hide the splash when start up. However, a white blank screen show instead of my app 1st screen.
on Android case, after update config.xml AutoHideSplashScreen to true, the splash screen show time much less (about 2s only). Also, as before, it can show my app 1st screen after close the splash screen.
P.S.
I will try "hello cordova" sample
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Arthur T. wrote:
- no, it is bug of XDK Cordova Build Package as it used project name (the ? from ?.xdk, ?.xdke) instead of get from App Name in build settings to set <name></name> in config.xml
You're correct, it is a bug. The xdk-to-cli script, however, does the right thing. If you use the xdk-to-cli script you must make sure that you either exit the XDK before running it, or push your app to our backend servers using the Test tab, or switch to a different project (to make sure the current state of the XDK config files get written to disk).
Arthur T. wrote:
- could I use variable and value pair of plugin for the purpose of customization after include the plugin?
You might be able to, I'm not sure, you'll have to check to see what can be done with a plugin.xml file in the Cordova docs. Personally, I think it would be simpler to just use the xdk-to-cli script I referenced above.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Arthur T. wrote:
fyi: I update config.xml AutoHideSplashScreen to true and now iOS will hide the splash when start up. However, a white blank screen show instead of my app 1st screen.
on Android case, after update config.xml AutoHideSplashScreen to true, the splash screen show time much less (about 2s only). Also, as before, it can show my app 1st screen after close the splash screen.
This sounds like a bug in the apps, you may have to do some debugging with remote CDT. See this doc page for options > https://software.intel.com/en-us/xdk/docs/intel-xdk-debug-and-test-overview < If you have access to a Mac, I recommend you use this technique for debugging > https://software.intel.com/en-us/xdk/docs/intel-xdk-debug-and-test-overview#WebInspectorRemote < and for your Android app, I recommend you use this technique > https://software.intel.com/en-us/xdk/docs/intel-xdk-debug-and-test-overview#RemoteChromeDevTools < also outlined here > https://software.intel.com/en-us/xdk/docs/using-remote-chrome-devtools-to-debug-android-cordova-apps <
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Paul F. (Intel) wrote:
This sounds like a bug in the apps
You are right, it is due to <meta http-equiv="Content-Security-Policy" content="default-src 'self' 'unsafe-eval' data: blob: filesystem: ws: gap://ready cdvfile: https://ssl.gstatic.com *; style-src * data: 'unsafe-inline'; script-src * 'unsafe-inline' 'unsafe-eval'; img-src * data: 'unsafe-inline'; connect-src * 'unsafe-inline'; child-src * gap://ready; "> in index.html
I need to use gap://ready instead of gap: and put in child-src too
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
FYI: I finally able to build ios by CLI. Previously fail to sign because I follow doc use "codeSignIdentity": "iPhone Developement" in build.json. However, after check from keychain. I should use "iPhone Developer" (I guess this is default for iOS now)
Now I'm working on android case
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
same error as before which is
:compileReleaseJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
/Users/AT/Desktop/ParentPortal-pgb-cli-2017-0523-1876/platforms/android/src/org/crosswalk/engine/XWalkWebViewEngine.java:55: error: XWalkWebViewEngine is not abstract and does not override abstract method evaluateJavascript(String,ValueCallback<String>) in CordovaWebViewEngine
public class XWalkWebViewEngine implements CordovaWebViewEngine {
^
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
1 error
:compileReleaseJavaWithJavac FAILEDFAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':compileReleaseJavaWithJavac'.
> Compilation failed; see the compiler error output for details.
Is there any way to get rid of this error without using phone gap build?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Arthur T. wrote:
Is there any way to get rid of this error without using phone gap build?
If PhoneGap Build works, why do you not want to use it? After all, our build system is going away, so building with PhoneGap Build is the right way to go. We have identified the App Name bug and are fixing that; in the meantime, you can use the xdk-to-cli script as a workaround or modify the config.xml before you send to PhoneGap Build.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I'm struggle on that too, although I can use your suggested way in handling our 'private' plugin (make different version in github for our different app) But for CLI case, I can simply copy all plugins to CLI project folder and it will use that instead of get from internet. So I don't need to handle our private plugin and need to submit a version to github for each app (although just do once for each app).
In fact, I'm not concern the app name bug as
1. I'm sure it is simple to fix by your colleagues and most probably available soon
2. before fix version available, I can simply edit the exported config.xml <name></name> to proper value
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3977 solved the app name issue when use Create Package in BUILD tab. However, it has different behavior between ios and android version on default app name language. For android case, it will default as the one I entered in build settings. e.g. We customize it with our plugin (npm plugin id: localize-app-name) and only specify values-en for android. So in android case, other than English language, our app will show the app name set in build settings. However in ios case, we specify en.lproj, zh-hant.lproj for the plugin and it will show en.lproj app name whenever device is not Traditional Chinese (not default as the one we set in build settings)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I do not understand what you mean by:
However in ios case, we specify en.lproj, zh-hant.lproj for the plugin and it will show en.lproj app name whenever device is not Traditional Chinese (not default as the one we set in build settings)
Can you provide more details?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Forget the app name issue I stated for iOS as that is iOS app behavior.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How to make our plugin in GitHub repo with different version no. for XDK to select from ?
Now it only get the latest version from repo and there is no choice to change in XDK UI
P.S.
I tried make the plugin with multiple release in repo, but no use.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
There are a variety of ways to do this, you could:
- create a unique branch for each variation of your plugin
- assign a tag to each variant within a single repo
- create a new release for each variant within the repo
- use a specific commit reference, if you do not like tags or branches
- or just create a unique plugin repo for each variant of your plugin
You can reference tags and commits as "git ref tags" (a GitHub "release" is just another way of creating a tag or "ref tag"). The plugin add tool provides you with the means to reference a unique git ref tag when you add the plugin. See the very end of this doc page for some help with specifying a "git ref tag" > https://software.intel.com/en-us/xdk/docs/add-manage-project-plugins <
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thanks, it works now.
How other plugin has option to change version?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Arthur T. wrote:
How other plugin has option to change version?
I don't understand your question. Are you asking how can you change the version of a plugin? Or are you asking can a plugin change the version of your app? Or???
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- « Previous
-
- 1
- 2
- Next »