mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 908530 part 3. Stop including xpcpublic.h in DOMJSProxyHandler.h. r=khuey
This commit is contained in:
parent
18e33f4b17
commit
e7f14418b2
@ -9,7 +9,7 @@
|
||||
#include "mozilla/Attributes.h"
|
||||
#include "mozilla/Likely.h"
|
||||
|
||||
#include "xpcpublic.h"
|
||||
#include "jsproxy.h"
|
||||
#include "nsStringGlue.h"
|
||||
|
||||
#define DOM_PROXY_OBJECT_SLOT js::PROXY_PRIVATE_SLOT
|
||||
@ -26,6 +26,21 @@ enum {
|
||||
|
||||
template<typename T> struct Prefable;
|
||||
|
||||
extern int HandlerFamily;
|
||||
inline void* ProxyFamily() { return &HandlerFamily; }
|
||||
|
||||
inline bool IsDOMProxy(JSObject *obj, const js::Class* clasp)
|
||||
{
|
||||
MOZ_ASSERT(js::GetObjectClass(obj) == clasp);
|
||||
return (js::IsObjectProxyClass(clasp) || js::IsFunctionProxyClass(clasp)) &&
|
||||
js::GetProxyHandler(obj)->family() == ProxyFamily();
|
||||
}
|
||||
|
||||
inline bool IsDOMProxy(JSObject *obj)
|
||||
{
|
||||
return IsDOMProxy(obj, js::GetObjectClass(obj));
|
||||
}
|
||||
|
||||
class BaseDOMProxyHandler : public js::BaseProxyHandler
|
||||
{
|
||||
public:
|
||||
|
@ -447,21 +447,6 @@ SimulateActivityCallback(bool aActive);
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
||||
extern int HandlerFamily;
|
||||
inline void* ProxyFamily() { return &HandlerFamily; }
|
||||
|
||||
inline bool IsDOMProxy(JSObject *obj, const js::Class* clasp)
|
||||
{
|
||||
MOZ_ASSERT(js::GetObjectClass(obj) == clasp);
|
||||
return (js::IsObjectProxyClass(clasp) || js::IsFunctionProxyClass(clasp)) &&
|
||||
js::GetProxyHandler(obj)->family() == ProxyFamily();
|
||||
}
|
||||
|
||||
inline bool IsDOMProxy(JSObject *obj)
|
||||
{
|
||||
return IsDOMProxy(obj, js::GetObjectClass(obj));
|
||||
}
|
||||
|
||||
typedef JSObject*
|
||||
(*DefineInterface)(JSContext *cx, JS::Handle<JSObject*> global,
|
||||
JS::Handle<jsid> id, bool defineOnGlobal);
|
||||
|
Loading…
Reference in New Issue
Block a user