Closed Bug 1031331 Opened 5 years ago Closed 5 years ago

[homescreen] Do not show the contextmenu while in edit mode

Categories

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

defect
Not set

Tracking

(b2g-v2.0 fixed, b2g-v2.1 fixed)

RESOLVED FIXED
2.0 S5 (4july)
Tracking Status
b2g-v2.0 --- fixed
b2g-v2.1 --- fixed

People

(Reporter: vingtetun, Assigned: vingtetun, NeedInfo)

References

Details

(Whiteboard: [systemsfe])

Attachments

(1 file)

Attached patch bug1031331.patchSplinter Review
Christian, here is the followup I promised in bug 1028708, with a patch and the according test.
Assignee: nobody → 21
Attachment #8447190 - Flags: review?(crdlc)
Whiteboard: [systemsfe]
Target Milestone: --- → 2.0 S5 (4july)
QA Whiteboard: [VH-FL-blocking-][VH-FC-blocking?]
From a UX perspective this bug should not be a blocker.
(In reply to jsavory from comment #3)
> From a UX perspective this bug should not be a blocker.

Given this lets consider approval for uplift here once ready and not block on it.
blocking-b2g: 2.0? → ---
QA Whiteboard: [VH-FL-blocking-][VH-FC-blocking?] → [VH-FL-blocking-][VH-FC-blocking-]
Comment on attachment 8447190 [details] [diff] [review]
bug1031331.patch

LGTM although I prefer to do it via events

window.addEventListener('gaiagrid-editmode-start', this);
window.addEventListener('gaiagrid-dragdrop-end', this);

case 'gaiagrid-editmode-start':

  this.container.removeEventListener('contextmenu', this);

case 'gaiagrid-editmode-end':

  this.container.addEventListener('contextmenu', this);

But as I said you can follow this idea or yours, up to you, both of them are good. Although if you implement the code based on events please fix it [1]. The event was named wrongly

[1] https://github.com/mozilla-b2g/gaia/blob/master/shared/elements/gaia_grid/js/grid_dragdrop.js#L376
Attachment #8447190 - Flags: review?(crdlc) → review+
Sorry window.addEventListener('gaiagrid-dragdrop-end', this); instead of window.addEventListener('gaiagrid-editmode-end', this); I cannot edit my last comment as in github :)
(In reply to Cristian Rodriguez (:crdlc) from comment #6)
> Sorry window.addEventListener('gaiagrid-dragdrop-end', this); instead of
> window.addEventListener('gaiagrid-editmode-end', this); I cannot edit my
> last comment as in github :)

Yeah, that's one of the thing that is painful on bugzilla (but I really prefer the rest of the review interface).
Comment on attachment 8447190 [details] [diff] [review]
bug1031331.patch

This is needed for the vertical homescreen.
Attachment #8447190 - Flags: approval-gaia-v2.0?(bbajaj)
Attachment #8447190 - Flags: approval-gaia-v2.0?(bbajaj) → approval-gaia-v2.0+
Hi Vivien,
    Could you provide the detailed reproduce steps for me to verify this bug?

Thank you!
Flags: needinfo?(21)
You need to log in before you can comment on or make changes to this bug.