Bug 1931796. Don't UpdateCanvasBackground when the display we are building is for...
[gecko.git] / xpcom / base / nsrootidl.idl
blob364d0b75ebadaa1e2d32895c0e138fcadd3078b7
1 /* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6 /**
7 * Root idl declarations to be used by all.
8 */
10 %{C++
12 #include "nscore.h"
13 #include "nsID.h"
16 * Forward declarations for new string types
18 #include "nsStringFwd.h"
20 struct JSContext;
23 * Forward declaration of mozilla::dom::Promise
25 namespace mozilla {
26 namespace dom {
27 class Promise;
28 } // namespace dom
29 } // namespace mozilla
33 typedef long long PRTime;
35 // If we ever want to use `size_t` in scriptable interfaces, this will need to
36 // be built into the xpidl compiler, as the size varies based on platform.
37 native size_t(size_t);
39 [ptr] native voidPtr(void);
40 [ptr] native charPtr(char);
41 [ptr] native unicharPtr(char16_t);
43 [ref, nsid] native nsIDRef(nsID);
44 [ref, nsid] native nsIIDRef(nsIID);
45 [ref, nsid] native nsCIDRef(nsCID);
47 [ptr, nsid] native nsIDPtr(nsID);
48 [ptr, nsid] native nsIIDPtr(nsIID);
49 [ptr, nsid] native nsCIDPtr(nsCID);
51 // NOTE: Be careful in using the following 3 types. The *Ref and *Ptr variants
52 // are more commonly used (and better supported). Those variants require
53 // nsMemory alloc'd copies when used as 'out' params while these types do not.
54 // However, currently these types can not be used for 'in' params. And, methods
55 // that use them as 'out' params *must* be declared [notxpcom] (with an explicit
56 // return type of nsresult). This makes such methods implicitly not scriptable.
57 // Use of these types in methods without a [notxpcom] declaration will cause
58 // the xpidl compiler to raise an error.
59 // See: http://bugzilla.mozilla.org/show_bug.cgi?id=93792
61 [nsid] native nsIID(nsIID);
62 [nsid] native nsID(nsID);
63 [nsid] native nsCID(nsCID);
65 [ptr] native nsQIResult(void);
67 [ref, utf8string] native AUTF8String(ignored);
68 [ref, utf8string] native AUTF8StringRef(ignored);
69 [ptr, utf8string] native AUTF8StringPtr(ignored);
71 [ref, cstring] native ACString(ignored);
72 [ref, cstring] native ACStringRef(ignored);
73 [ptr, cstring] native ACStringPtr(ignored);
75 [ref, astring] native AString(ignored);
76 [ref, astring] native AStringRef(ignored);
77 [ptr, astring] native AStringPtr(ignored);
79 [ref, jsval] native jsval(jsval);
80 native jsid(jsid);
82 [ptr, promise] native Promise(ignored);