We want our users to be able to disable some features (ie. IDL attributes) with a pref. To make sure the web reacts correctly, we want those features to not be seen as part of the object. Currently, the only way to do that is per-interface in classinfo which requires to restart Firefox when the pref is toggled. We should find a simple way to make this per-instance: to have the pref being considered when the object is created. Which means users will be able to toggle the pref and reload. IRC log that might be more clear that my explanations: [19:35] < mounir> bz: could you be more explicit about the classinfo vs prototype thing for the pref? [19:35] <@bz> mounir: yes [19:35] <@bz> mounir: right now the only way we have to pref stuff is on a per-interface level [19:36] <@bz> mounir: and that happens by munging the set of interfaces exposed in classinfo [19:36] <@bz> mounir: this set is computed once, afaik [19:36] <@bz> mounir: so is static for process lifetime [19:36] <@bz> mounir: there was some talk about adding a way to declare a pref on a per-member basis in the idl [19:36] <@bz> mounir: and check that pref in the code that defines properties on the releavant DOM prototype [19:37] <@bz> mounir: prototypes are set up per-page [19:37] < mounir> bz: but there is currently no way to do that, right? [19:37] <@bz> yes
So my thinking was that we could add a IDL annotation, only support it for quicktubbed methods, and have the quickstubs prototype setup do the right thing. Sound feasible?
https://bugzilla.mozilla.org/show_bug.cgi?id=1472046 Move all DOM bugs that haven’t been updated in more than 3 years and has no one currently assigned to P5. If you have questions, please contact :mdaly.
Priority: -- → P5
This is basically done in the Web IDL bindings, on a per-page basis.
Status: NEW → RESOLVED
Last Resolved: 4 months ago
Depends on: 580070
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.