Closed
Bug 737432
Opened 12 years ago
Closed 12 years ago
Add permission prompt to b2g
Categories
(Firefox OS Graveyard :: General, defect)
Tracking
(Not tracked)
RESOLVED
DUPLICATE
of bug 742092
People
(Reporter: jstraus, Assigned: jstraus)
Details
Attachments
(2 files, 1 obsolete file)
4.50 KB,
patch
|
Details | Diff | Splinter Review | |
13.63 KB,
patch
|
Details | Diff | Splinter Review |
Gecko needs a way to securely prompt the user for permission to use services. Once this is done, the hack to always set permissions in b2g.js and b2g/chrome/content/shell.js can be removed.
Assignee | ||
Comment 1•12 years ago
|
||
This is a first pass at getting a UI in place. More of the infrastructure is filled in so that once we have a good way of putting up a permissions prompt it will be easier to fill in. It includes a sample call in CameraContent. I also changed the CID to match nsIContentPermissionPrompt.idl. showAlertNotification doesn't seem to be working yet, so it is just a place holder. I considered (and tried) a number of things to get a real UI. This included a special app to be the dialog, injecting a dialog into each of the apps (like the keyboard), or sending an event to the home screen (somewhat like SMS). None seems satisfactory. Suggestions would be welcome.
Attachment #610598 -
Flags: review?(fabrice)
Comment 2•12 years ago
|
||
Comment on attachment 610598 [details] [diff] [review] First pass towards providing a UI Review of attachment 610598 [details] [diff] [review]: ----------------------------------------------------------------- The general approach is correct. What we need is a way to remote the permission UI call to the homescreen, like we do for the mozNotification and mozApps APIs. There's a thread on dev-webapi about this subject: http://groups.google.com/group/mozilla.dev.webapi/browse_thread/thread/db29059c5c8e2527# ::: b2g/components/B2GComponents.manifest @@ +16,1 @@ > don't change that. This is the UUID of the interface, which can be implemented by different components that have their own CID. ::: b2g/components/CameraContent.js @@ +74,5 @@ > + permprompt.prompt({ > + type: "content-camera", > + uri: principal.URI, > + window: null, > + element: null, one of these must be not null. ::: b2g/components/ContentPermissionPrompt.js @@ +18,1 @@ > unused?
Attachment #610598 -
Flags: review?(fabrice)
Assignee | ||
Comment 3•12 years ago
|
||
Fabrice: Fixed the CID. I thought it fixed a problem I was having earlier, but I guess not. I tested with the updated CID. I'm looking at the notification thread you mentioned. Is there a bug entered for this and/or anyone working on it? Otherwise, I'll take a stab at getting it started.
Assignee: nobody → jstraus
Attachment #610598 -
Attachment is obsolete: true
Attachment #610659 -
Flags: review?(fabrice)
Comment 4•12 years ago
|
||
bug 742092 added the Gecko <-> gaia glue for ContentPermissionPrompt
Updated•12 years ago
|
Attachment #610659 -
Flags: review?(fabrice)
Assignee | ||
Comment 5•12 years ago
|
||
Added more of a UI for permission prompt.
Attachment #613771 -
Flags: review?(fabrice)
Assignee | ||
Comment 6•12 years ago
|
||
There is a pull-request in for the gaia changes.
Updated•12 years ago
|
Summary: Add permission prompt to gecko → Add permission prompt to b2g
Comment 7•12 years ago
|
||
Comment on attachment 613771 [details] [diff] [review] more fleshing out the UI Review of attachment 613771 [details] [diff] [review]: ----------------------------------------------------------------- https://hg.mozilla.org/integration/mozilla-inbound/rev/6854bda609ae added mostly the same change to b2g/components/ContentPermissionPrompt.js Can you check if it's enough? We need some gaia tests here. Also, why do we need to patch browser/* ? this is desktop firefox land, that doesn't have content-camera support and will never have (this will be replaced by webrtc-based code).
Attachment #613771 -
Flags: review?(fabrice)
Assignee | ||
Comment 8•12 years ago
|
||
Bug 742092 accomplishes the same thing
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•