Closed Bug 807281 Opened 13 years ago Closed 7 years ago

a way to notify the social provider of changes from the main window

Categories

(Firefox Graveyard :: SocialAPI, enhancement)

19 Branch
x86
Linux
enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: em, Unassigned)

Details

(Whiteboard: [needs-api-change] [testday-20130301])

Since the provider will likely just use the main window for profile changes, and activity relevant to the provider could happen in the main window, it makes sense to have a way for the main window to notify the sidebar of changes. For example, the user clicks the profile link from the ambient menu (or from the sidebar). This opens a tab and the user is free to update their profile as a normal web application. When the users presses "Save" they would accept sidebar relevant changes to be immediately reflected in the sidebar. Some kind of signal from the main document to the worker is required. Security is an issue, so perhaps the worker/manifest could provide a whitelist of domains which are allowed to send it messages.
There was some talk of exposing the navigator.mozSocial object to all pages in the provider's domain. We need to think through the implications of this, but would that meet your requirement?
I would likely just call "navigator.mozSocial.getWorker().post", so yes, that would work. I'd worry that allowing complete access to mozSocial may be less secure than a strict post-message only interface. One important thing I would need however is to be able to provide multiple allowed domains in the manifest. For example, our provider would be served from "mozsocial.cliqz.com" but the main website will be on just "cliqz.com" with some account settings on "accounts.cliqz.com".
Sorry for the bug-spam. This is a first cut at bugs that need (or potentially need) a change to the social api to be implemented appropriately.
Whiteboard: [needs-api-change]
Status: UNCONFIRMED → NEW
Ever confirmed: true
Whiteboard: [needs-api-change] → [needs-api-change] [testday-20130301]
SocialAPI was removed from Firefox 57 and is no longer available in any current release.
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → WONTFIX
Product: Firefox → Firefox Graveyard
You need to log in before you can comment on or make changes to this bug.