PhoneGap的1.4环绕煎茶触摸2.X - 关于性能呢?性能、PhoneGap

2023-09-12 02:53:11 作者:學生學生ゝ越學越生

我建立一个多平台的平板电脑的应用程序与PhoneGap的1.4只使用它的web视图包装它,然后我的工作我的魔法与煎茶触摸2框架。通过多我的意思的iOS 5.X +和Android 3.0+(现在)。

这个程序是伟大的工作,到目前为止,其所有功能在两个系统上工作,但......在Android平板电脑(三星GalaxyTab的),它的很慢。 发生了什么?我可以做一些事情,或者它只是Android的限制吗?

感谢

里卡多·佩列: HTTP://edge$c$ctechology.blogspot.pt/

*的的修改的* (我试图让这个帖子煎茶社区比较有用)

  

煎茶触摸,像许多其他的JavaScript框架并非性能最好的例子,由于JavaScript的本身。

     

那么为什么使用煎茶触摸?

        在我的情况: 多的(IOS,安卓,Windows手机,黑莓,Windows,Mac OSX版,Linux的共享的code 80-90%。 )   

由于Android的系统缺乏视觉pre-过程中减轻性能问题:

CSS3沉重的可视化流程:

避免渐变 避免阴影 避免转换和动画

好的MVC做法:

请不要使用更多的意见和你实际显示 pre-渲染/ pre-DATAFETCH时尽量避免同时呈现和数据处理

对于任何scrollviews,overscroll应在Android上禁用。我已经在Android设备上测试了许多煎茶触摸2应用程序和overscroll原因,因为延误严重不愉快的经验和滞后。

:由蒂姆阮(P我一直在挖掘自己的帖子,对不起花花公子)(上的Galaxy Tab,Nexus S的,以及一些HTC的测试) 解决方案

我也一样。我测试过许多我的三星GalaxyTab的煎茶触摸2应用和性能真的很可怕。有一个事实(这可能实际有一部分原因)是,iOS的做了很多pre-过程和计算渲染,使之看起来更光滑用户的外观和感觉,而Android倾向于渲染和功放前;在旅途中同时处理。

在一般情况下,它可能是说,要建立在Javascript的每一个跨平台的移动应用程序,像煎茶触摸,iOS的性能是比Android显著好。然而,煎茶触摸的开发团队正在尽力改善这一点,希望这将是下一版本更好。你可以看到这篇文章的iOS和放大器; Android设备的性能比较。

http://www.sencha.com/blog/sencha-touch-2-developer-$p$pview/

PS:虽然它的很多相关的操作系统的限制,还可以优化您的应用程序,使其在Android设备上有更好的表现。以我的经验,最好的做法是:

请不要使用CSS3太多。 让你的DOM尽可能小。

希望它帮助。

I'm building a multiplatform tablet app wrapping it with Phonegap 1.4 using just its webview, then I work my magic with the Sencha Touch 2 framework. By multiplatform I mean iOS 5.X+ and Android 3.0+ (for now).

四核性能引领风暴 One X售价3550元

This app is working great so far, all its features work on both systems but... On the Android tablet (Samsung GalaxyTab) its really slow. What's happening? Can I do something about it, or its just android's limit?

Thanks

Ricardo Perre: http://edgecodetechology.blogspot.pt/

*EDIT* (I'm trying to make this post somewhat useful to sencha community)

Sencha Touch, like many other Javascript Frameworks are not the best example of performance due to javascript itself.

Then Why use Sencha Touch?

In my case: Multiplatform (iOS, Android, Windows Phone, Blackberry, Windows, Mac OSX, Linux. Sharing 80-90% of the code)

Mitigating performance issues due to lack of visual pre-process in Android systems:

CSS3 heavy visual process:

Avoid Gradients Avoid Shadows Avoid Transformations and animations

Good MVC practices:

Don't use more views and you actually showing Pre-render / Pre-datafetch when possible to avoid render and data process simultaneously

For any scrollviews, overscroll should be disabled on Android. I've tested many Sencha Touch 2 applications on Android devices and overscroll causes badly unpleasant experience because of delays and lags. (tested on Galaxy Tab, Nexus S, and some HTCs) by Thiem Nguyen (I've been mining your posts, sorry dude :P)

解决方案

Same here. I've tested many of my Sencha Touch 2 applications on Samsung GalaxyTab and the performance is really terrible. There's a fact (which maybe a part of actual reason) that, iOS does many pre-process and calculation before rendering to make it seems smoother to user's look and feel, while Android tends to render & process simultaneously on the go.

In general, it could be say that, to every cross-platform mobile apps built on Javascript, like Sencha Touch, iOS performance is significantly better than Android. However, Sencha Touch dev team is trying their best to improve this, hopefully it would be better in next releases. You could see this article about iOS & Android devices performance comparison.

http://www.sencha.com/blog/sencha-touch-2-developer-preview/

PS: While it's much relevant to the OS's limit, you can also optimize your app to make it perform better on Android devices. To my experience, the best practice is:

Do NOT use CSS3 too much. Keep your DOM as minimal as possible.

Hope it helps.

 
精彩推荐
图片推荐