Closed Bug 1234217 Opened 10 years ago Closed 10 years ago

UI should prevent the user that he's trying to close the tab while the wizard is running

Categories

(Firefox OS Graveyard :: B2gInstaller, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: jlorenzo, Assigned: gerard-majax)

References

Details

Attachments

(2 files, 3 obsolete files)

STR 1. Click on "Flash device" 2. Close the tab (by either Ctrl+W, clicking on the close button, quitting Firefox) Expected results Like on some website, a modal pop up should appear warning the user about the effects of closing this page. Actual results No warning, the tab gets closed. This is harmful if the user didn't want to intentionally close the window.
While I agree, https://developer.mozilla.org/en-US/docs/Web/Events/beforeunload does not work in this case. Maybe because of "about:" ?
Flags: needinfo?(jlorenzo)
Attached file b2g-installer PR (obsolete) —
Discussed on IRC. We don't know what was different between your first attempt and this changeset. This one works on a default profile.
Flags: needinfo?(jlorenzo)
Attachment #8706902 - Flags: review?(lissyx+mozillians)
Assignee: nobody → jlorenzo
Comment on attachment 8706902 [details] [review] b2g-installer PR I cannot tell why I got this non working for several hours yesterday.
Attachment #8706902 - Attachment is obsolete: true
Attachment #8706902 - Flags: review?(lissyx+mozillians)
(In reply to Alexandre LISSY :gerard-majax from comment #3) > I cannot tell why I got this non working for several hours yesterday. Discussed offline: This PR has been deprecated because Alexandre thinks it's preferable to show the warning only when the Flashing modal is shown. Some other work is required before enabling this feature.
Depends on: 1238945
(In reply to Johan Lorenzo [:jlorenzo] (QA) from comment #4) > (In reply to Alexandre LISSY :gerard-majax from comment #3) > > I cannot tell why I got this non working for several hours yesterday. > > Discussed offline: This PR has been deprecated because Alexandre thinks it's > preferable to show the warning only when the Flashing modal is shown. Some > other work is required before enabling this feature. Risky time is the window during which we: - check device's compatibility - pull blobs - build new images - fastboot flash Out of those steps, we should not mess with the user
Flags: needinfo?(jlorenzo)
(In reply to Alexandre LISSY :gerard-majax from comment #5) > > Risky time is the window during which we: > - check device's compatibility > - pull blobs > - build new images > - fastboot flash > I'd add the download part too. Firefox Desktop warns the user if they are some downloads happening when he tries to quit. Then, I'd extend it to when the flashing modal window is shown.
Flags: needinfo?(jlorenzo)
yeah, that covers what I had in mind :)
Still some work needed but basics are here.
Attachment #8707068 - Attachment is obsolete: true
Now should be good :)
Attachment #8707486 - Attachment is obsolete: true
Attachment #8707494 - Flags: review?(dale)
(In reply to Alexandre LISSY :gerard-majax from comment #11) > https://treeherder.mozilla.org/#/jobs?repo=try&revision=5bab6de0eb56 Green!
Comment on attachment 8707494 [details] [diff] [review] Prompt user to avoid unintentional risky tab close Sweet gave this a test and works well, cheers
Attachment #8707494 - Flags: review?(dale) → review+
Attached file PR of the patch
Assignee: jlorenzo → lissyx+mozillians
Status: NEW → ASSIGNED
Attachment #8709532 - Flags: review+
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: