I would rather not add dependency on that JSM etc... This should be enough:

```js
function isWindowPrivate(window) {
  return window.QueryInterface(Ci.nsIInterfaceRequestor)
                  .getInterface(Ci.nsIWebNavigation)
                  .QueryInterface(Ci.nsILoadContext).
                   usePrivateBrowsing
}
```