Closed Bug 801068 Opened 12 years ago Closed 12 years ago

Requesting to get the camera, clicking away from the prompt does not persist the prompt and instead, immediately denies the permission prompt

Categories

(Firefox :: Site Permissions, defect)

defect
Not set
normal

Tracking

()

VERIFIED FIXED
Firefox 19

People

(Reporter: jsmith, Assigned: dao)

References

Details

(Whiteboard: [getUserMedia] [blocking-gum-])

Attachments

(1 file, 1 obsolete file)

Steps:

1. Request the camera with video: true on mozGetUserMedia
2. Click away from the doorhanger prompt

Expected:

The prompt should operate the same as the geolocation prompt - it should sit as an icon next to the back button, no PERMISSION_DENIED should be fired until the user explicitly does not allow access to the camera.

Actual:

The prompt disappears following the behavior of a "Don't Allow," resulting in PERMISSION_DENIED be fired back from gUM.

Additional Notes:

Not sure if it was intentional to remove this doorhanger behavior for this feature in Firefox Desktop or not. Think of this bug being a parity issue between how the geolocation prompt works vs. camera access prompt works.
Blocks: 729522
Whiteboard: [getUserMedia]
Whiteboard: [getUserMedia] → [getUserMedia] [blocking-gum-]
Attached patch patch (obsolete) — Splinter Review
I'm not sure why you added this code, Anant.
Assignee: nobody → dao
Status: NEW → ASSIGNED
Attachment #673716 - Flags: review?(anant)
Comment on attachment 673716 [details] [diff] [review]
patch

Review of attachment 673716 [details] [diff] [review]:
-----------------------------------------------------------------

Dão, I added this code to make sure there was a way for users to deny access to the camera.

We discussed this at a recent meeting and concluded that the current behavior is incorrect, but so is the version in the patch. We need to add an explicit deny button to the doorhanger which will send the response:deny message back to the backend. Dismissing the popup without selecting allow/deny should simply hide the popup, which this patch does.
Attachment #673716 - Flags: review?(anant)
Attached patch patch v2Splinter Review
Attachment #673716 - Attachment is obsolete: true
Attachment #674202 - Flags: review?(anant)
Comment on attachment 674202 [details] [diff] [review]
patch v2

Looks great Dão. My only concern is that it will take two clicks for the user to deny access since the button appears in a dropdown. Is it not possible to display a button adjacent to the accept option in a PopupNotification?
Attachment #674202 - Flags: review?(anant) → review+
It should also be possible for the user to "blacklist" a given site from asking for access again, I filed bug 804611 to track that.
(In reply to Anant Narayanan [:anant] from comment #4)
> Comment on attachment 674202 [details] [diff] [review]
> patch v2
> 
> Looks great Dão. My only concern is that it will take two clicks for the
> user to deny access since the button appears in a dropdown. Is it not
> possible to display a button adjacent to the accept option in a
> PopupNotification?

It's possible to hack this in. The PopoNotification API doesn't really allow for it, but maybe we should change that.
https://hg.mozilla.org/mozilla-central/rev/40c02387c9b7
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
Target Milestone: --- → Firefox 19
Keywords: verifyme
QA Contact: jsmith
Verified on 10/26 build.
Status: RESOLVED → VERIFIED
Keywords: verifyme
Component: General → Device Permissions
You need to log in before you can comment on or make changes to this bug.