Subj : Re: Sharing Javascript objects between different XUL windows. To : Peter Wilson From : Brendan Eich Date : Thu Dec 23 2004 02:37 pm Peter Wilson wrote: > Peter Wilson wrote: > OK. My misunderstanding. JS Wrappers give this effect. > > I need to ask the XPCOM board how to check if two JS objects are the > same XPCOM object. > It was worthwhile going through the exercise this far, so I'll answer here -- thanks for showing all the details, I bet it will help someone else. XPCOM object identity says you QueryInterface to nsISupports, then compare pointers. So in JS, that would be o.nsISupports == o2.nsISupports, if memory serves. /be .