Closed Bug 978011 Opened 11 years ago Closed 11 years ago

Unload properly Image Loader when syncing/importing

Categories

(Firefox OS Graveyard :: Gaia::Contacts, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(blocking-b2g:1.3+, b2g-v1.3 fixed, b2g-v1.3T fixed, b2g-v1.4 fixed)

RESOLVED FIXED
1.4 S3 (14mar)
blocking-b2g 1.3+
Tracking Status
b2g-v1.3 --- fixed
b2g-v1.3T --- fixed
b2g-v1.4 --- fixed

People

(Reporter: gerard-majax, Assigned: crdlc)

References

Details

Attachments

(1 file)

Follow-up of bug 970832. We need some code to properly remove the event listeners when performing import operations. Copy/paste of the suggestion that was on the pull request [https://github.com/mozilla-b2g/gaia/pull/16721]: > I have also another additional idea to make the importer module safer if you're comfortable with it > > https://github.com/mozilla-b2g/gaia/blob/master/apps/communications/contacts/js/importer_ui.js#L781 > Just after the user clicks on "Import button", we could call something like this: > > imgLoader.unload(); // or imgLoader.uninit() or imgLoader.destroy(),... > > This method should remove the listeners "scroll" and "onupdate" thought. > I guess that to keep listeners running does not make sense here. > > What do you think @jmcanterafonseca ?
Nominating for 1.4 since this solution looks safer, but requires some extra code that we don't want to add taking into account timeframe for 1.3
blocking-b2g: --- → 1.4?
Assignee: nobody → crdlc
Not a blocker, just land it if ready before March 17th
blocking-b2g: 1.4? → ---
Status: NEW → ASSIGNED
Attached file Patch v1
Thanks for the review
Attachment #8386631 - Flags: review?(jmcf)
Comment on attachment 8386631 [details] Patch v1 works perfectly. please land once you get a green Travis.
Attachment #8386631 - Flags: review?(jmcf) → review+
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Flags: in-testsuite+
Target Milestone: --- → 1.4 S3 (14mar)
Tested on master (see environment details below). It is working as expected, with 1951 contacts in gmail server and selecting 10 contacts with photo, all the photos have been properly imported so nominating to v1.3 Device: Hamachi Platform version: 30.0a1 Build ID: 20140307120944 Gecko: 83c9562 Gaia: 5bc9b5c
blocking-b2g: --- → 1.3?
Comment on attachment 8386631 [details] Patch v1 NOTE: Please see https://wiki.mozilla.org/Release_Management/B2G_Landing to better understand the B2G approval process and landings. [Approval Request Comment] [Bug caused by] (feature/regressing bug #): Contacts photos are not imported properly. See bug 970832 [User impact] if declined: High impact on the experience. Phone appear as buggy [Testing completed]: Yes, in master by the QA team. Also unit tests available [Risk to taking this patch] (and alternatives if risky): Very low risk. [String changes made]: The image loader component is unloaded properly
Attachment #8386631 - Flags: approval-gaia-v1.3?(fabrice)
Dupe of a 1.3+, which makes this a 1.3+ as well.
blocking-b2g: 1.3? → 1.3+
Attachment #8386631 - Flags: approval-gaia-v1.3?(fabrice) → approval-gaia-v1.3+
Hi Ryan, Could you please help us with the uplift to v1.3 branch?. Thanks!
Flags: needinfo?(ryanvm)
v1.3: 5b75c885f0f29412942188fec0433e86ffdf36c3
Flags: needinfo?(ryanvm)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: