changing the manifest

The place to discuss anything and everything about running your LiveCode on Android

Moderators: Klaus, FourthWorld, heatherlaine, robinmiller, kevinmiller

Post Reply
markhinnebusch
Posts: 39
Joined: Thu May 17, 2018 7:32 pm
Location: Florida, USA

changing the manifest

Post by markhinnebusch » Thu Sep 05, 2019 10:49 pm

I'm still working on making my app run seamlessly in Chromebook and i have everything working except that when the user clicks on the resize, Chromebook thinks it has resized the app but it doesn't send any event for me to handle. So, I want to disable resizing in the manifest. However, when I add android:resizable="false" to the <supports-screens> section, then the build fails saying it cannot generate the package manifest.

Is there some way around this? I'm on 9.5.0

thanks for any help. I feel the cuts of being on the bleeding edge, LOL.

markhinnebusch
Posts: 39
Joined: Thu May 17, 2018 7:32 pm
Location: Florida, USA

Re: changing the manifest

Post by markhinnebusch » Thu Sep 05, 2019 11:39 pm

I just saw another post that mentions a custom manifest in the copy files, so i am going to try that. Sorry for the chatter.

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5138
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: changing the manifest

Post by jacque » Fri Sep 06, 2019 6:06 pm

Please continue the chatter. I will need to run my apk on a Chromebook soon. What issues did you need to address? Anything I need to be aware of?

Early tests showed that most things worked okay, but I did have a crash when trying to set the keyboard return key type if the machine was in desktop mode using the hardware keyboard (makes sense I guess) but did not crash when it was rotated into tablet mode where there is only the on-screen keyboard.

What should I watch out for? You and I may be the only ones playing with this right now since Chromebooks aren't officially supported by LC.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

markhinnebusch
Posts: 39
Joined: Thu May 17, 2018 7:32 pm
Location: Florida, USA

Re: changing the manifest

Post by markhinnebusch » Fri Sep 06, 2019 8:25 pm

So far, just 3, one a show-stopper.

First is the size limitation of an app in the Play Store. We got around that by downloading any extra content from an update server on first use.

Second, it looks like you cannot write to cache ("temporary" and 'cache" special folders map to the same place) so had to write to "documents". On the chromebook, documents is the app data and it goes away when you uninstall the app.

The third, and for us, a killer. Our app is designed for laptops so portrait really doesn't cut it. So, we build with landscape as the initial format. Everything is OK. BUT, if the user clicks on the "resize" icon that Chromebook shows at the top of the screen, it resizes the app but doesn't throw any event that LC consumes. This leave the app in a state where it thinks it is full screen but the chromeOS thinks it is resized. The only way out is to force stop the app, but then when you re-open it, it opens resized and if you fullscreen it with the chromebook fullscreen icon, it is messed up again, so you have to force stop it again.

This is why I am trying to use a custom manifest, since it seems that the only thing the chromebook will interpret is the manifest. However, when I use the manifest in the copy files mechanism, the app loads fine on an Android but the package installer won't install it on the Chromebook, giving me a "The was a problem parsing the package" error. Note that Android has no problem.

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5138
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: changing the manifest

Post by jacque » Fri Sep 06, 2019 8:59 pm

Thanks, that's all good info to know. For the third problem, have you tried limiting the orientation to landscape using "mobileSetAllowedOrientations"? That may force the app to landscape permanently and I think it then fillsl the available screen. I haven't tried it on a Chromebook but it might work.

Also, do you not get a "resizeStack" message when the user clicks the resize icon?
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

markhinnebusch
Posts: 39
Joined: Thu May 17, 2018 7:32 pm
Location: Florida, USA

Re: changing the manifest

Post by markhinnebusch » Fri Sep 06, 2019 10:40 pm

I tried "mobileSetAllowedOrientations". Doesn't help. No stack resize event. As near as I can tell, no event at all.

markhinnebusch
Posts: 39
Joined: Thu May 17, 2018 7:32 pm
Location: Florida, USA

Re: changing the manifest

Post by markhinnebusch » Fri Sep 06, 2019 10:51 pm

I think the solution must be adding android:resizeableActivity to the manifest. However, no matter what I do, I cannot change the manifest. I tried modifying the manifest.xml that comes with LC and that breaks the build (reported elsewhere, so no surprise). Then I tried adding my own manifest.xml to the copy files. I made it an exact copy of the original LC manifest (as the values are populated). I did that by using Android Studio to open the .apk and copied the manifest.xml contents to my custom one, then added android:resizeableActivity to the <activity>. Did a build and got exactly the same thing (looking in Android studio again) as without the custom manifest. Then i tried a stripped down custom manifest with just the required attributes at the parent node and an activity with just android:resizeableActivity. Again, after the build, absolutely no change.

So, I guess either I just don't know how to use the manifest merge capability of LC 9.5.0 or it is broken.

I haven't been able to find any documentation at all on how to use it.

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5138
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: changing the manifest

Post by jacque » Sat Sep 07, 2019 12:10 am

As I understand it, you can add your custom instructions to a copy of the manifest and use that, or just use one that has only the extra things you need. Your entries will override the default ones in LC's manifest, and add yours if they don't exist in the default.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

jacque
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 5138
Joined: Sat Apr 08, 2006 8:31 pm
Location: Minneapolis MN
Contact:

Re: changing the manifest

Post by jacque » Sat Sep 07, 2019 5:13 pm

Instead of using Android Studio, put your edited manifest into the Copy Files pane of the standalone settings in LC. That's what determines whether it's included or not. Then create the standalone.

I never use Studio, I only installed it to get the build tools. Otherwise you don't really need it.

Edit : oops, I just saw in the other thread that you already tried that. I don't have any other suggestions, sorry.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Post Reply

Return to “Android Deployment”