Slide 1

Slide 1 text

TableView Naoya Ito How to optimize for Titanium Mobile

Slide 2

Slide 2 text

HBFav github.com/naoya/HBFav

Slide 3

Slide 3 text

TableView gotta optimize

Slide 4

Slide 4 text

use Instruments it's bundled with xcode

Slide 5

Slide 5 text

No content

Slide 6

Slide 6 text

oops! Red = Blended Layer

Slide 7

Slide 7 text

"borderRadius" brings up Offscreen-Rendered Yellow. Do not use cornered elements on TableView

Slide 8

Slide 8 text

Scaling Image causes Copied Image & Blended Layer. Use original size of the image

Slide 9

Slide 9 text

All Labels have a transparent background. There is no public way to make them opaque...

Slide 10

Slide 10 text

Hacking Titanium Mobile build/iphone/Classes/TiUILabel.m // override -(void)setBackgroundColor_:(id)color { if ([color isKindOfClass:[UIColor class]]) { label.backgroundColor = color; } else { TiColor *ticolor = [TiUtils colorValue:color]; label.backgroundColor = [ticolor _color]; } }

Slide 11

Slide 11 text

before after achieve a faster & smoother scroll

Slide 12

Slide 12 text

USE Instruments then remove Blended Layer & Offscreen-Rendering

Slide 13

Slide 13 text

Thanks! cf. www.fenrir.co.jp/blog/2011/10/ios-animation-tuning.html Design inspired by: zachholman.com/posts/slide-design-for-developers/