Closed Bug 656037 Opened 9 years ago Closed 9 years ago

core JavaScript functions should be exposed in Jetpack module scope somehow

Categories

(Add-on SDK Graveyard :: General, enhancement, P1)

enhancement

Tracking

(Not tracked)

RESOLVED INVALID
Future

People

(Reporter: dietrich, Unassigned)

References

Details

some window-scope functions are not available, such as btoa and atob. we should audit these "web scope" functions to see what else is missing.

currently you can work around it by using chrome privs to get access to XUL window via XPCOM, or you can write a content-script (eg: round-trip the data to an open tab or whatever).

both options are pretty bad.
According to the note on https://developer.mozilla.org/en/DOM/window.btoa , btoa and atob are accessible to JS XPCOM components without a window reference.

Doesn't work out of the box in the SDK, though. :(
It would be useful to figure out whether this bug is specifically about btoa/atob or all such functions, and if the latter, exactly which such functions are encompassed by "all".  (Either way, this is important, so P1.)
OS: Mac OS X → All
Priority: -- → P1
Hardware: x86 → All
Target Milestone: --- → Future
I filed bug 675141 so that work can proceed on exposing btoa() and atob(), without having to wait for the discussion of what else should be added.
Marking anything that potentially looks like a feature request as "enhancement", sorry for the bugspam. :)
Severity: normal → enhancement
Being replaced by the Hug the Web Feature page. File individual bugs for specific things to expose.
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.