Quantcast
Channel: Appcelerator Developer Center Q&A Unanswered Questions 20
Viewing all articles
Browse latest Browse all 8068

Slow tableView performance in ios

$
0
0

Hello everybody, I asked this kind of question already but I didn't realize all the information. the problem is that i have tableView with pretty simple rows, and it works perfect on android, in my case - galaxy s4 mini. but when I tried to run it on iPhone 4s, the performance is really bad. The first problem that I realize is that i had too much xml complex code and many layouts for my tableViewRow. so I tried to remove some of the layouts and make the row simpler. here is the code now:

<TableView dataCollection = "swap" height="Ti.UI.FILL" top = "0">
            <TableViewRow className = "swapQueue" layout="vertical" onClick = "rowClicked" height="Ti.UI.SIZE" backgroundColor="{backgroundColor}" queueId = "{queueId}" queueTime = "{queueTime}">
                <View class = "HeightSizeWidthSize">
                    <Label id = "numOfQueue" class = "HeightSizeWidthSize" top = "5" right = "5">{queueNum}</Label>
                    <Label id = "queueName" class = "HeightSizeWidthSize" right = "100">{userName}</Label>
                    <ImageView image = "/images/default.png" height = "70" right = "25" width = "70" borderRadius = "35" borderWidth = "4" borderColor = "#57ADE0"/>
                    <Label id = "queueTime" class = "HeightSizeWidthSize" left = "5">{queueTime}</Label>
                    <View height="Ti.UI.SIZE" height = "1" backgroundColor="black" top = "0"></View>
                </View>
            </TableViewRow>
        </TableView>
app.tss:
".HeightSizeWidthSize":{
    height: Ti.UI.SIZE,
    width: Ti.UI.SIZE
}
I saw that if there is even one layout, the performance is got very slow and it seems that it load every row just when I over it, and just when i finish to over on all the rows, the performance improved. without the layout the performance are much better. what can i do without layout? how will i adapt the components to every size of mobile screen? I use SKD 3.5.1. Thank's everybody!

Viewing all articles
Browse latest Browse all 8068

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>