Speed issue in SenchaTouch and Android

1,437 views
Skip to first unread message

Pavel

unread,
Mar 8, 2011, 6:42:42 PM3/8/11
to phonegap
Hello,

I'm a newbie in a phonegap community.
I'm using SenchaTouch in my application and and I have tried to wrap
basic example from Sencha.com into phonegap framework(http://
wiki.phonegap.com/w/page/30862722/phonegap-android-eclipse-
quickstart).

It works correctly on Android(and Android emulator too)... but it VERY
slow(rendering, animation)

Is it possible to increase the speed of application? because native
android UI components are very quickly.

Thanks for advice

Michael Herger

unread,
Mar 9, 2011, 3:30:52 AM3/9/11
to phon...@googlegroups.com
> It works correctly on Android(and Android emulator too)... but it VERY
> slow(rendering, animation)

Is the same code faster in the device's web browser? Most likely a Sencha
issue.

--

Michael

Pavel

unread,
Mar 9, 2011, 5:01:19 AM3/9/11
to phonegap
Hi Michael, thank you for your answer.

> Is the same code faster in the device's web browser? Most likely a Sencha  
> issue.

Yes, you are right. The Sencha's examples works perfectly in Chrome or
Safary, but they very slow on Android Emulator..
I just wrapped a basic example from Sencha..

Maybe there is some other practices of using senchatouch, which will
increase the speed of the application?

My example is:

-- index.html
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;
charset=utf-8">
<meta name="viewport" content="width=device-width; initial-
scale=1.0; maximum-scale=1.0; minimum-scale=1.0; user-scalable=0;" />
<link rel="stylesheet" href="sencha-touch.css" type="text/css">

<title>List</title>
<script type="text/javascript" src="sencha-touch.js"></script>
<script type="text/javascript" src="app.js"></script>
</head>
<body></body>
</html>

--app.js

Ext.setup({
tabletStartupScreen: 'tablet_startup.png',
phoneStartupScreen: 'phone_startup.png',
icon: 'icon.png',
glossOnIcon: false,
onReady : function() {
Ext.regModel('Contact', {
fields: ['firstName', 'lastName']
});

var groupingBase = {
itemTpl: '<div class="contact2"><strong>{firstName}</
strong> {lastName}</div>',
selModel: {
mode: 'SINGLE',
allowDeselect: true
},
grouped: true,
indexBar: true,

onItemDisclosure: {
scope: 'test',
handler: function(record, btn, index) {
alert('Disclose more info for ' +
record.get('firstName'));
}
},

store: new Ext.data.Store({
model: 'Contact',
sorters: 'firstName',

getGroupString : function(record) {
return record.get('firstName')[0];
},

data: [
{firstName: 'Tommy', lastName: 'Maintz'},
{firstName: 'Ed', lastName: 'Spencer'},
{firstName: 'Jamie', lastName: 'Avins'},
{firstName: 'Aaron', lastName: 'Conran'},
{firstName: 'Dave', lastName: 'Kaneda'},
{firstName: 'Michael', lastName: 'Mullany'},
{firstName: 'Abraham', lastName: 'Elias'},
{firstName: 'Jay', lastName: 'Robinson'}

]
})
};


if (!Ext.is.Phone) {
new Ext.List(Ext.apply(groupingBase, {
floating: true,
width: 350,
height: 370,
centered: true,
modal: true,
hideOnMaskTap: false
})).show();
}
else {
new Ext.List(Ext.apply(groupingBase, {
fullscreen: true
}));
}
}
});


Thanks

Michael Herger

unread,
Mar 9, 2011, 5:17:17 AM3/9/11
to phon...@googlegroups.com
> Yes, you are right. The Sencha's examples works perfectly in Chrome or
> Safary, but they very slow on Android Emulator..

Forget the emulator. It _is_ terribly slow, not comparable to an actual
device. I gave up testing in the emulator unless when I needed to test
screen resolutions or Android versions I don't have on a device.

--

Michael

Pavel

unread,
Mar 9, 2011, 5:26:09 AM3/9/11
to phonegap

> Forget the emulator. It _is_ terribly slow, not comparable to an actual  
> device.

I run this example on Android Device too. It works a little faster..
but still very slow.

Thanks.

Ade Goddard

unread,
Mar 9, 2011, 6:02:19 AM3/9/11
to phon...@googlegroups.com
Do u mean the initial render time or r u experiecing speed issues throughout?

Sencha does take a few seconds to initially render from my experience.
But is pretty fast after this. I believe u can customise the actual
build stripping out components u dont use. Which in theory should
speed things up.

Also only suitable for higher end android os 2.2

Sent from my iPhone

> --
> You received this message because you are subscribed to the Google
> Groups "phonegap" group.
> To post to this group, send email to phon...@googlegroups.com
> To unsubscribe from this group, send email to
> phonegap+u...@googlegroups.com
> For more options, visit this group at
> http://groups.google.com/group/phonegap?hl=en?hl=en
>
> For more info on PhoneGap or to download the code go to www.phonegap.com

Pavel

unread,
Mar 9, 2011, 6:10:33 AM3/9/11
to phonegap
> Do u mean the initial render time or r u experiecing speed issues throughout?

I meant both cases

> Sencha does take a few seconds to initially render from my experience.
> But is pretty fast after this. I believe u can customise the actual
> build stripping out components u dont use. Which in theory should
> speed things up.

Thank you for advice

> Also only suitable for higher end android os 2.2

Oh.. I tried to use this example on Android 2.1 - update1.
Do you think that the speed problem appears on Android OS < 2.2?

Thanks

Michael Herger

unread,
Mar 9, 2011, 6:41:39 AM3/9/11
to phon...@googlegroups.com
> Oh.. I tried to use this example on Android 2.1 - update1.
> Do you think that the speed problem appears on Android OS < 2.2?

What device? I've been running an app on a ZTE Blade (2.1, 600MHz), and
it's really slow. But it would fly on the HTC Desire (2.2) or Samsung
Galaxy S (2.1).

--

Michael

Pavel

unread,
Mar 9, 2011, 7:29:16 AM3/9/11
to phonegap
> What device? I've been running an app on a ZTE Blade (2.1, 600MHz), and  
> it's really slow. But it would fly on the HTC Desire (2.2) or Samsung  
> Galaxy S (2.1).

I tested on HTC Wildfire(Qualcomm MSM 7225 528 MHz) (2.1-update1)

Isaac Zepeda

unread,
Mar 9, 2011, 1:02:56 PM3/9/11
to phonegap
Sencha Touch is heavy, in some Android Devices it doesn't run ok, just
like other apps like angry birds and so, but in new devices with good
hardware it runs perfect, sencha touch also runs perfect on iOS.

Regards,

Furqonuddin Ramdhani

unread,
Mar 10, 2011, 12:59:19 AM3/10/11
to phon...@googlegroups.com
I got flickring problem when changing page between tabpanel with android, so I  disable the animation effect :). Here another tips from sencha guys :
--
You received this message because you are subscribed to the Google
Groups "phonegap" group.
To post to this group, send email to phon...@googlegroups.com
To unsubscribe from this group, send email to
phonegap+u...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/phonegap?hl=en?hl=en

For more info on PhoneGap or to download the code go to www.phonegap.com



--
Salam
Furqonuddin Ramdhani

Adrian Goddard

unread,
Mar 10, 2011, 2:55:39 AM3/10/11
to phon...@googlegroups.com
.x-panel {
    -webkit-backface-visibility: hidden;
}
also fixes i apparently

Pavel

unread,
Mar 10, 2011, 4:45:38 PM3/10/11
to phonegap
Thank you for you replies.

It seems that it is impossible to use SenchaTouch on a "weak" Andorid
devices, or developer should use a few practices of optimization...

I hope that the Sencha team will improve memory usage in this
framework.

MikeMc

unread,
Mar 11, 2011, 9:13:29 AM3/11/11
to phon...@googlegroups.com
I actually ended up ditching Sencha Touch for this very reason, performance.

Currently as of 1.0.1a if you plan on supporting low end android devices or most android 2.1 devices, i would suggest you avoid Sencha Touch.


Pavel

unread,
Mar 11, 2011, 10:01:46 AM3/11/11
to phonegap
But is exist alternative for the SenchaTouch?
Because I run JQuery Mobile and it works very slow too :)

Robert Fletcher

unread,
Mar 11, 2011, 10:45:51 AM3/11/11
to phon...@googlegroups.com

it could be that transitions are too much for the older phones to handle.

i use jqtouch and it runs pretty good on my motorola droid 1

Reply all
Reply to author
Forward
0 new messages