nsIDocShellTreeItem's parent and treeOwner attributes are not scriptable To be precise, it is the setters for these attributes that are not scriptable. They store pointers to the given interface pointers without calling AddRef! :( It would be very bad if someone tried to assign a value to either of these from JS or some other nsXPTCStub-based language binding.
Created attachment 166204 [details] [diff] [review] v1 patch simple patch (browser.js actually reads the treeOwner attribute)
Status: NEW → ASSIGNED
Target Milestone: --- → mozilla1.8beta
14 years ago
Attachment #166204 - Flags: superreview?(bzbarsky) → superreview+
Comment on attachment 166204 [details] [diff] [review] v1 patch ok, r=biesi, but this seems to be somewhat ugly... can we keep an nsIWeakReference or something here, instead of having to mark this noscript?
Attachment #166204 - Flags: review?(cbiesinger) → review+
it is ugly, but i don't have time to fix it properly. if you want to cut a patch, please do. currently, we don't have any script callers, and it would seem there is no need for script callers :-/
actually, i can think of some people who would want to use this...
smaug's evil code iirc :)
Well, then his code must result in crashes or other badness.
of course :), but he's working on that.
This patch does not affect my code, not at least for now.
Status: ASSIGNED → RESOLVED
Last Resolved: 14 years ago
Resolution: --- → FIXED
Just a heads-up -- I plan to remove the ability to set the parent on this interface in the very near future. I'm not sure about the treeowner yet.... We really want to only allow setting it on "root" docshells, somehow.
You need to log in before you can comment on or make changes to this bug.