Android browser is slow

Bringing the internet highway into your project? Building FTP, HTTP, email, chat or other client solutions?

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

LiadTal6
Posts: 36
Joined: Sat Jul 25, 2015 5:26 pm

Android browser is slow

Post by LiadTal6 » Mon Jan 15, 2018 8:17 am

Hello,

Maybe here someone could help me.

I'm using the browser widget in LC 8.1.6 for my android app.
I don't know why, but when I open my app in my phone, the browser is very slow..
I saw that someone write in another topic that you need to set every object to "dynamic", so I did it. It helped just a little bit, but when I scroll the internet page that the browser is giving, it's still slow.
Please help me to fix this problem, I'm sure that all of the people here not getting satisfied from a slow browser..
Any tip for solving the problem would be great.

Thank you very much.

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

Re: Android browser is slow

Post by jacque » Mon Jan 15, 2018 9:27 pm

The layermode does not apply to the content of the browser widget, so setting it to dynamic won't help much. Layermode only affects objects that move, and the widget itself is stationary.

I haven't seen what you describe so I'm not sure why you would see lag. You could do a test with a plain stack containing only a browser widget and see if it is slow there. If so, something in your scripts may be interfering. Or try going to a different URL and see if that is also slow. That would tell you if the slowdown is due to the web page you are loading.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

LiadTal6
Posts: 36
Joined: Sat Jul 25, 2015 5:26 pm

Re: Android browser is slow

Post by LiadTal6 » Thu Jan 25, 2018 11:57 pm

Hi,

I don't know why, but I missed your reply.

The browser widget is slow for every URL that I give.
I tried to create a stack with the browser widget only but it's still has lags.
What can I do? It's very strange and I have to find a solution.
I don't think that the lags created by wrong code, because the browser widget works without any code, you just need to give it the URL link.

Something else in the browser in Android is that when I scroll the page up and down it has frames in the sides of the browser. How can I remove them?
I don't know what is the name of this frames, but they are 50% transparent and rounded.

I would very appreciate any kind of help for solving this problems.

Thanks!

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

Re: Android browser is slow

Post by jacque » Fri Jan 26, 2018 12:50 am

The latest stable release is LC 8.1.8. I don't know if that will be better but it is worth updating to see if it behaves better.

I'm not sure what you mean by the side frames, if you can post a screenshot that would help.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

LiadTal6
Posts: 36
Joined: Sat Jul 25, 2015 5:26 pm

Re: Android browser is slow

Post by LiadTal6 » Mon Jan 29, 2018 7:08 pm

Hi,

I downloaded the new version, nothing changed, still a lot of lags.
What can I do? I have to get rid of all of that lags as fast as possible.

Please someone could help me? I don't know what is the source for all of this lags.
In the iPhone version, it's working perfect.

The frames is less important now, first of all I need to fix all the lags.

Thanks.

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

Re: Android browser is slow

Post by jacque » Mon Jan 29, 2018 7:24 pm

I think the frames you mention are the scrollbar indicators. This is normal Android browser behavior and users will expect it.

The lag may be due to the processing power of the test device. If you can, try it on a different phone. Are you using the Android emulator? That's always very slow and does not represent normal speed at all. You need to test on a real physical device.

How long is the lag? If you go to google.com is that also slow?
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

LiadTal6
Posts: 36
Joined: Sat Jul 25, 2015 5:26 pm

Re: Android browser is slow

Post by LiadTal6 » Mon Jan 29, 2018 7:44 pm

I'm not using the android emulator, I'm using 4 different android phones and my friends help me with that too, there is phones with lot of lags and there is phones with fewer lags, but they all have lags.

I don't know if I can tell what is the time of the lag, but the app isn't stuck, the scrolling is very slowly and sometimes when the user scroll down suddenly the page is scroll up to the start of the page.

If I go to google it's still slow. when I open every page of my app in regular browser it's working perfect.

Maybe the problem is happened because slow rate frame, I don't really know.

There is a way to increase the frame rate or something like that?
That's very strange that for everyone the browser works fine but for me it's slowly.

Thanks.

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

Re: Android browser is slow

Post by jacque » Mon Jan 29, 2018 9:09 pm

I can't think of any reason why that would happen. Does your app do any background processing? For example, do you use "send <message> to <object> in <time>"? Are there other scripts running at the same time the browser widget is showing?

Sorry, I can't think of anything else. You could try setting the acceleratedRendering of the stack to true. I don't think that applies to widgets but you could try it.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

LiadTal6
Posts: 36
Joined: Sat Jul 25, 2015 5:26 pm

Re: Android browser is slow

Post by LiadTal6 » Mon Jan 29, 2018 10:05 pm

No, it has nothing in the background.

How can I set the acceleratedRendering to true?

Maybe I'm not saving the app in the way I should save it? Or maybe I need to download something in the Android SDK Manager?

Maybe you could tell me how do you save you Android application or using the browser?

I think that if everyone is satisfied from the browser maybe I do something wrong in the saving process..

I love LC, but I'm started to be desperate from it..

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

Re: Android browser is slow

Post by jacque » Mon Jan 29, 2018 10:35 pm

AcceleratedRendering is a stack property, you can set it in a preOpenStack or preOpenCard handler. See "acceleratedRendering" in the dictionary. But to be honest, I don't think it will affect widgets.

There is no special trick to saving an Android apk. Just make sure you have included the widget library and the internet library in the Inclusions pane of standalone settings. I'm sure you must have done that already because your stack is showing a browser widget and it does connect to the internet.

Are you using the free version of LC? The paid versions include a more advanced internet library called TSNet that is used by default. If you have TSNet, also include that in the Inclusion pane. If the Inclusion pane is not enabled, change the standalone settings to select inclusions manually.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

FourthWorld
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 9801
Joined: Sat Apr 08, 2006 7:05 am
Location: Los Angeles
Contact:

Re: Android browser is slow

Post by FourthWorld » Mon Jan 29, 2018 10:44 pm

My understanding is that LC's browser widget uses Android's built-in browser engine.

How does performance compare on the same device when using the stock browser included with your phone?
Richard Gaskin
LiveCode development, training, and consulting services: Fourth World Systems
LiveCode Group on Facebook
LiveCode Group on LinkedIn

LiadTal6
Posts: 36
Joined: Sat Jul 25, 2015 5:26 pm

Re: Android browser is slow

Post by LiadTal6 » Tue Jan 30, 2018 3:49 pm

FourthWorld wrote:
Mon Jan 29, 2018 10:44 pm
How does performance compare on the same device when using the stock browser included with your phone?
I'm sorry but I didn't understand your question. Can you explain yourself please?
jacque wrote:
Mon Jan 29, 2018 10:35 pm
AcceleratedRendering is a stack property, you can set it in a preOpenStack or preOpenCard handler. See "acceleratedRendering" in the dictionary. But to be honest, I don't think it will affect widgets.

There is no special trick to saving an Android apk. Just make sure you have included the widget library and the internet library in the Inclusions pane of standalone settings. I'm sure you must have done that already because your stack is showing a browser widget and it does connect to the internet.

Are you using the free version of LC? The paid versions include a more advanced internet library called TSNet that is used by default. If you have TSNet, also include that in the Inclusion pane. If the Inclusion pane is not enabled, change the standalone settings to select inclusions manually.
I set to true the "acceleratedRendering" but nothing changed.

Before your message I didn't include the Inclusions that you mentioned. I added them now but nothing changed.

I'm using the "LC Indy", and I added the "TSnet", nothing happened.

I created just for example a stack with only one browser that presenting only one page of my app, it's still had lot of lags. When I open the same page in the regular browser it's much faster. I really don't know why.

Maybe someone here could send me an example for a browser that works good in Android?

Maybe it's because I didn't download all the SDK's from the "Android SDK Manager"?

I really need your help here.

Thank you all.

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

Re: Android browser is slow

Post by jacque » Tue Jan 30, 2018 6:50 pm

FourthWorld wrote:
Mon Jan 29, 2018 10:44 pm
My understanding is that LC's browser widget uses Android's built-in browser engine
Yes, you're right, I was just grasping at straws.

LiadTal6, there is no special way to set up a browser widget, it is the same as what you're doing. Just assign a url and it works. Is the lag just a little slow or is it several seconds? Is it only when loading the page, or does it lag when clicking and scrolling too?
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

LiadTal6
Posts: 36
Joined: Sat Jul 25, 2015 5:26 pm

Re: Android browser is slow

Post by LiadTal6 » Tue Jan 30, 2018 8:03 pm

The loading of the page is fine.
The main lag is when the user scroll up and down in the browser, it's not a clear scroll.
For example, sometimes when the user scroll down the page is going up, or when the user scroll down it's very slow and not fast as when I'm using regular browser.
I don't know really how to explain it more then that.

Maybe you know this site, but I created page in "Jotform" and then put it in the browser. In this specific pages that I created with "Jotform" it has more lags in the LC browser, but when I launch it in regular browser it's fine.

Maybe now you have any idea?

Thanks.

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

Re: Android browser is slow

Post by jacque » Tue Jan 30, 2018 8:23 pm

Post a URL please.
Jacqueline Landman Gay | jacque at hyperactivesw dot com
HyperActive Software | http://www.hyperactivesw.com

Post Reply

Return to “Internet”