UI lags when scrolling through scopes
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
unity8 (Ubuntu) |
Confirmed
|
Undecided
|
Unassigned |
Bug Description
Some causes ruled out:
1. OA in scopes can't be to blame as I have tested with and without it enabled, and with and without it present in the code (https:/
2. Location can't be blamed either (for the same reasons as above, as well as removing location service usage from the shell plugin itself).
3. When profiling the QML and C++ code, I saw no indication that the shell plugin was doing anything process intensive enough to cause any hold up. In fact, it seems to be doing a pretty good job handling calls from the UI thread asynchronously.
Observations made when profiling unity8:
1. The QML ListView component updates its current item index when the next item reaches half-way across the screen (therefore, in mid animation between scopes). There doesn't look to be any serious blocking actions taking place during the onIsCurrentChange, setActive, etc. methods that I could find, but we should keep this in mind.
2. ResultsModel:
3. If you pull down to refresh any scope, then continuously move the dash left and right, the dash movement is smooth until results start showing up in the scope, at which point you see a lag as they appear. The lag observed here is almost definitely the same lag we see when scrolling through scopes (jittering as results start to pop up in scopes as they populate).
(NOTE: All of the above points were observed with and without the latest unity8 performance fixes in rtm silo 8)
summary: |
- UI lags when scrolling through favorited scopes + UI lags when scrolling through scopes |
> 2. ResultsModel: :data() seems to be called constantly while scrolling a
> scope up and down. I assume this should only be called once per result
> item (This doesn't explain the horizontal scrolling lag, but it may
> explain some vertical lag).
That's not exactly right. It will be called for every role*every result
that a delegate is created for. Delegates are recycled and created as
they go out and into view, respectively.
*If* it's called on the same result and same role multiple times, while
the result is constantly in view, that'd be a problem indeed.