Closed
Bug 1010236
Opened 10 years ago
Closed 10 years ago
[Messages] When setting recipients.length, we should rerender only if the length decreases
Categories
(Firefox OS Graveyard :: Gaia::SMS, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: julienw, Assigned: solfen, Mentored)
Details
(Whiteboard: [sms-papercuts][lang=js][good first bug])
Attachments
(1 file)
In [1], we render each time the length is set. However it seems we set "recipients.length = 0" several times during some panel transitions, and as a result we call "render" each of this times. "render" does not look to be that expensive when length is 0, but it stills do some operations that look costly even in that case (accessing textContent, calling scrollIntoView). Therefore it looks to be an helpful and easy change to prevent calling it too many times. [1] https://github.com/mozilla-b2g/gaia/blob/5fd5c952cdc6f89613ccf6fa0f7f39fee9898bb9/apps/sms/js/recipients.js#L147
Reporter | ||
Updated•10 years ago
|
Whiteboard: [sms-papercuts]
Reporter | ||
Updated•10 years ago
|
Mentor: felash
Whiteboard: [sms-papercuts] → [sms-papercuts][lang=js][good first bug]
Assignee | ||
Comment 1•10 years ago
|
||
Attachment #8515508 -
Flags: review?(felash)
Reporter | ||
Updated•10 years ago
|
Assignee: nobody → maxime.lore
Reporter | ||
Comment 2•10 years ago
|
||
Comment on attachment 8515508 [details] [review] pull request github r=me with a nit
Attachment #8515508 -
Flags: review?(felash) → review+
Reporter | ||
Comment 3•10 years ago
|
||
Fixed the nits and landed: master: 1aec4232e08f4e123692aa8c025d57b924da138c thanks a lot Maxime!
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•