kernel32: Add a structure to store all the information about an executable.
[wine] / dlls / mshtml / nsiface.idl
1 /*
2  * Copyright 2005-2007 Jacek Caban for CodeWeavers
3  *
4  * This library is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2.1 of the License, or (at your option) any later version.
8  *
9  * This library is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17  */
18
19 /* 
20  * NOTE:
21  * This file is not a typical idl file. Interfaces in this file are XPCOM
22  * interfaces (NOT MSCOM!), but we generate the header file with WIDL
23  * compatible with XPCOM, usable in C code.
24  */
25
26 cpp_quote("#define GECKO_VERSION \"1.0.0\"")
27 cpp_quote("#define GECKO_VERSION_STRING \"Wine Gecko \" GECKO_VERSION")
28
29 import "wtypes.idl";
30
31 cpp_quote("#ifdef WINE_NO_UNICODE_MACROS")
32 cpp_quote("#undef GetForm")
33 cpp_quote("#undef SetPort")
34 cpp_quote("#endif")
35
36 typedef HRESULT nsresult;
37 typedef ULONG nsrefcnt;
38
39 typedef IID nsID;
40 typedef IID nsIID;
41 typedef nsIID nsCID;
42 typedef REFIID nsIIDRef;
43 typedef nsIIDRef nsCIDRef;
44
45 typedef void** nsQIResult;
46 typedef WCHAR PRUnichar;
47 typedef ULONG PRUint32;
48 typedef LONG PRInt32;
49 typedef WORD PRUint16;
50 typedef INT16 PRInt16;
51 typedef BYTE PRUint8;
52 typedef BOOL PRBool;
53 typedef LARGE_INTEGER PRInt64;
54 typedef ULARGE_INTEGER PRUint64;
55 typedef PRUint64 DOMTimeStamp;
56 typedef PRUint32 nsLoadFlags;
57
58 typedef struct {
59     void *v;
60     void *d1;
61     PRUint32 d2;
62     void *d3;
63 } nsCStringContainer;
64
65 typedef struct {
66     void *v;
67     void *d1;
68     PRUint32 d2;
69     void *d3;
70 } nsStringContainer;
71
72 typedef nsCStringContainer nsACString;
73 typedef nsStringContainer nsAString;
74
75 interface nsIWebBrowserChrome;
76 interface nsILoadGroup;
77 interface nsIDOMNode;
78 interface nsIDOMDocument;
79 interface nsIDOMEvent;
80 interface nsIEditor;
81 interface nsISelectionController;
82 interface nsITransactionManager;
83 interface nsITransaction;
84 interface nsIInlineSpellChecker;
85 interface nsIOutputStream;
86 interface nsIEditorObserver;
87 interface nsIEditActionListener;
88 interface nsIDocumentStateListener;
89 interface nsIDOMCSSStyleSheet;
90 interface nsIDOMDocumentView;
91 interface nsIDocumentObserver;
92 interface nsIDOMWindow;
93
94 interface IMoniker;
95
96 [
97     object,
98     uuid(00000000-0000-0000-c000-000000000046),
99     local
100 ]
101 interface nsISupports
102 {
103     nsresult QueryInterface(nsIIDRef riid, nsQIResult result);
104     nsrefcnt AddRef();
105     nsrefcnt Release();
106 }
107
108 /* Currently we don't need a full declaration of these interfaces */
109 typedef nsISupports nsISHistory;
110 typedef nsISupports nsIWidget;
111 typedef nsISupports nsIHttpHeaderVisitor;
112 typedef nsISupports nsIDOMBarProp;
113 typedef nsISupports nsIPrompt;
114 typedef nsISupports nsIAuthPrompt;
115 typedef nsISupports nsIDOMNamedNodeMap;
116 typedef nsISupports nsIDOMAttr;
117 typedef nsISupports nsIDOMDocumentType;
118 typedef nsISupports nsIDOMDOMImplementation;
119 typedef nsISupports nsIDOMCDATASection;
120 typedef nsISupports nsIDOMProcessingInstruction;
121 typedef nsISupports nsIDOMEntityReference;
122 typedef nsISupports nsIDOMHTMLFormElement;
123 typedef nsISupports nsIDOMHTMLOptionsCollection;
124 typedef nsISupports nsIWebProgressListener;
125 typedef nsISupports nsIDOMCSSValue;
126 typedef nsISupports nsIPrintSession;
127 typedef nsISupports nsIControllerCommandTable;
128 typedef nsISupports nsIPrincipal;
129 typedef nsISupports nsIAtom;
130 typedef nsISupports nsISupportsArray;
131 typedef nsISupports nsIContentFilter;
132 typedef nsISupports nsIDOMMediaList;
133 typedef nsISupports nsIDOMHTMLTableCaptionElement;
134 typedef nsISupports nsIDOMHTMLTableSectionElement;
135 typedef nsISupports nsIDOMClientRectList;
136 typedef nsISupports nsIDOMClientRect;
137 typedef nsISupports nsIDOMLocation;
138 typedef nsISupports nsIDocument;
139 typedef nsISupports nsIContent;
140 typedef nsISupports nsINode;
141 typedef nsISupports nsIStyleSheet;
142 typedef nsISupports nsIStyleRule;
143
144 [
145     object,
146     uuid(8bb35ed9-e332-462d-9155-4a002ab5c958),
147     local
148     /* FROZEN */
149 ]
150 interface nsIServiceManager : nsISupports
151 {
152     nsresult GetService(nsCIDRef aClass, nsIIDRef aIID, void **result);
153     nsresult GetServiceByContractID(const char *aContractID, nsIIDRef aIID, void **result);
154     nsresult IsServiceInstantiated(nsCIDRef aClass, nsIIDRef aIID, BOOL *_retval);
155     nsresult IsServiceInstantiatedByContractID(const char *aContractID, nsIIDRef aIID, BOOL *_retval);
156 }
157
158 [
159     object,
160     uuid(00000001-0000-0000-c000-000000000046),
161     local
162     /* FROZEN */
163 ]
164 interface nsIFactory : nsISupports
165 {
166     nsresult CreateInstance(nsISupports *aOuter, const nsIID *iid, void **result);
167     nsresult LockFactory(PRBool lock);
168 }
169
170 [
171     object,
172     uuid(db242e01-e4d9-11d2-9dde-000064657374),
173     local
174     /* FROZEN */
175 ]
176 interface nsIObserver : nsISupports
177 {
178     nsresult Observe(nsISupports *aSubject, const char *aTopic, const PRUnichar *aData);
179 }
180
181 [
182     object,
183     uuid(a88e5a60-205a-4bb1-94e1-2628daf51eae),
184     local
185     /* FROZEN */
186 ]
187 interface nsIComponentManager : nsISupports
188 {
189     nsresult GetClassObject(nsCIDRef aClass, nsIIDRef aIID, nsQIResult result);
190     nsresult GetClassObjectByContractID(const char *aContractID, nsIIDRef aIID, nsQIResult result);
191     nsresult CreateInstance(nsCIDRef aClass, nsISupports *aDelegate, nsIIDRef aIID,
192             nsQIResult result);
193     nsresult CreateInstanceByContractID(const char *aContractID, nsISupports *aDelegate,
194             nsIIDRef aIID, nsQIResult result);
195 }
196
197 [
198     object,
199     uuid(59e7e77a-38e4-11d4-8cf5-0060b0fc14a3),
200     local
201     /* FROZEN */
202 ]
203 interface nsIMemory : nsISupports
204 {
205     void *Alloc(/*size_t*/ int size);
206     void *Realloc(void *_ptr, /*size_t*/ int newSize);
207     void Free(void *_ptr);
208     nsresult HeapMinimize(PRBool immediate);
209     nsresult IsLowMemory(PRBool *_retval);
210 }
211
212 [
213     object,
214     uuid(9188bc85-f92e-11d2-81ef-0060083a0bcf),
215     local
216     /* FROZEN */
217 ]
218 interface nsIWeakReference : nsISupports
219 {
220     nsresult QueryReferent(const nsIID *riid, void **result);
221 }
222
223 [
224     object,
225     uuid(9188bc86-f92e-11d2-81ef-0060083a0bcf),
226     local
227     /* FROZEN */
228 ]
229 interface nsISupportsWeakReference : nsISupports
230 {
231     nsresult GetWeakReference(nsIWeakReference **_retval);
232 }
233
234 [
235     object,
236     uuid(033a1470-8b2a-11d3-af88-00a024ffc08c),
237     local
238     /* FROZEN */
239 ]
240 interface nsIInterfaceRequestor : nsISupports
241 {
242     nsresult GetInterface(const nsIID *riid, void **result);
243 }
244
245 [
246     object,
247     uuid(4a2abaf0-6886-11d3-9382-00104ba0fd40),
248     local
249     /* NOT_FROZEN */
250 ]
251 interface nsIRunnable : nsISupports
252 {
253     nsresult Run();
254 }
255
256 [
257     object,
258     uuid(d1899240-f9d2-11d2-bdd6-000064657374),
259     local
260     /* FROZEN */
261 ]
262 interface nsISimpleEnumerator : nsISupports
263 {
264     nsresult HasMoreElements(PRBool *_retval);
265     nsresult GetNext(nsISupports **_retval);
266 }
267
268 [
269     object,
270     uuid(fa9c7f6c-61b3-11d4-9877-00c04fa0cf4a),
271     local
272     /* FROZEN */
273 ]
274 interface nsIInputStream : nsISupports
275 {
276     nsresult Close();
277     nsresult Available(PRUint32 *_retval);
278     nsresult Read(char *aBuf, PRUint32 aCount, PRUint32 *_retval);
279     nsresult ReadSegments(nsresult (*aWriter)(nsIInputStream *aInStream, 
280             void *aClosure, const char *aFromSegment, PRUint32 aToOffset,
281             PRUint32 aCount, PRUint32 *aWriteCount),
282             void *aClosure, PRUint32 aCount, PRUint32 *_retval);
283     nsresult IsNonBlocking(PRBool *_retval);
284 }
285
286 [
287     object,
288     uuid(07a22cc0-0ce5-11d3-9331-00104ba0fd40),
289     local
290     /* FROZEN */
291 ]
292 interface nsIURI : nsISupports
293 {
294     nsresult GetSpec(nsACString *aSpec);
295     nsresult SetSpec(const nsACString *aSpec);
296     nsresult GetPrePath(nsACString *aPrePath);
297     nsresult GetScheme(nsACString *aScheme);
298     nsresult SetScheme(const nsACString *aScheme);
299     nsresult GetUserPass(nsACString *aUserPass);
300     nsresult SetUserPass(const nsACString *aUserPass);
301     nsresult GetUsername(nsACString *aUsername);
302     nsresult SetUsername(const nsACString *aUsername);
303     nsresult GetPassword(nsACString *aPassword);
304     nsresult SetPassword(const nsACString *aPassword);
305     nsresult GetHostPort(nsACString *aHostPort);
306     nsresult SetHostPort(const nsACString *aHostPort);
307     nsresult GetHost(nsACString *aHost);
308     nsresult SetHost(const nsACString *aHost);
309     nsresult GetPort(PRInt32 *aPort);
310     nsresult SetPort(PRInt32 aPort);
311     nsresult GetPath(nsACString *aPath);
312     nsresult SetPath(const nsACString *aPath);
313     nsresult Equals(nsIURI *other, PRBool *_retval);
314     nsresult SchemeIs(const char *scheme, PRBool *_retval);
315     nsresult Clone(nsIURI **_retval);
316     nsresult Resolve(const nsACString *relativePath, nsACString *_retval);
317     nsresult GetAsciiSpec(nsACString *aAsciiSpec);
318     nsresult GetAsciiHost(nsACString *aAsciiHost);
319     nsresult GetOriginCharset(nsACString *aOriginCharset);
320 }
321
322 [
323     object,
324     uuid(d6116970-8034-11d3-9399-00104ba0fd40),
325     local
326     /* FROZEN */
327 ]
328 interface nsIURL : nsIURI
329 {
330     nsresult GetFilePath(nsACString *aFilePath);
331     nsresult SetFilePath(const nsACString *aFilePath);
332     nsresult GetParam(nsACString *aParam);
333     nsresult SetParam(const nsACString *aParam);
334     nsresult GetQuery(nsACString *aQuery);
335     nsresult SetQuery(const nsACString *aQuery);
336     nsresult GetRef(nsACString *aRef);
337     nsresult SetRef(const nsACString *aRef);
338     nsresult GetDirectory(nsACString *aDirectory);
339     nsresult SetDirectory(const nsACString *aDirectory);
340     nsresult GetFileName(nsACString *aFileName);
341     nsresult SetFileName(const nsACString *aFileName);
342     nsresult GetFileBaseName(nsACString *aFileBaseName);
343     nsresult SetFileBaseName(const nsACString *aFileBaseName);
344     nsresult GetFileExtension(nsACString *aFileExtension);
345     nsresult SetFileExtension(const nsACString *aFileExtension);
346     nsresult GetCommonBaseSpec(nsIURI *aURIToCompare, nsACString *_retval);
347     nsresult GetRelativeSpec(nsIURI *aURIToCompare, nsACString *_retval);
348 }
349
350 [
351     object,
352     uuid(ef6bfbd2-fd46-48d8-96b7-9f8f0fd387fe),
353     local
354     /* FROZEN */
355 ]
356 interface nsIRequest : nsISupports
357 {
358     nsresult GetName(nsACString *aName);
359     nsresult IsPending(PRBool *_retval);
360     nsresult GetStatus(nsresult *aStatus);
361     nsresult Cancel(nsresult aStatus);
362     nsresult Suspend();
363     nsresult Resume();
364     nsresult GetLoadGroup(nsILoadGroup **aLoadGroup);
365     nsresult SetLoadGroup(nsILoadGroup *aLoadGroup);
366     nsresult GetLoadFlags(nsLoadFlags *aLoadFlags);
367     nsresult SetLoadFlags(nsLoadFlags aLoadFlags);
368 }
369
370 [
371     object,
372     uuid(fd91e2e0-1481-11d3-9333-00104ba0fd40),
373     local
374     /* FROZEN */
375 ]
376 interface nsIRequestObserver : nsISupports
377 {
378     nsresult OnStartRequest(nsIRequest *aRequest, nsISupports *aContext);
379     nsresult OnStopRequest(nsIRequest *aRequest, nsISupports *aContext, nsresult aStatusCode);
380 }
381
382 [
383     object,
384     uuid(1a637020-1482-11d3-9333-00104ba0fd40),
385     local
386     /* FROZEN */
387
388 interface nsIStreamListener : nsIRequestObserver
389 {
390     nsresult OnDataAvailable(nsIRequest *aRequest, nsISupports *aContext,
391                              nsIInputStream *aInputStream, PRUint32 aOffset, PRUint32 aCount);
392 }
393
394 [
395     object,
396     uuid(3de0a31c-feaf-400f-9f1e-4ef71f8b20cc),
397     local
398     /* FROZEN */
399 ]
400 interface nsILoadGroup : nsIRequest
401 {
402     nsresult GetGroupObserver(nsIRequestObserver **aGroupObserver);
403     nsresult SetGroupObserver(nsIRequestObserver *aGroupObserver);
404     nsresult GetDefaultLoadRequest(nsIRequest **aDefaultLoadRequest);
405     nsresult SetDefaultLoadRequest(nsIRequest *aDefaultLoadRequest);
406     nsresult AddRequest(nsIRequest *aRequest, nsISupports *aContext);
407     nsresult RemoveRequest(nsIRequest *aRequest, nsISupports *aContext, nsresult aStatus);
408     nsresult GetRequests(nsISimpleEnumerator **aRequests);
409     nsresult GetActiveCount(PRUint32 *aActiveCount);
410     nsresult GetNotificationCallbacks(nsIInterfaceRequestor **aNotificationCallbacks);
411     nsresult SetNotificationCallbacks(nsIInterfaceRequestor *aNotificationCallbacks);
412 }
413
414 [
415     object,
416     uuid(c63a055a-a676-4e71-bf3c-6cfa11082018),
417     local
418     /* FROZEN */
419 ]
420 interface nsIChannel : nsIRequest
421 {
422     nsresult GetOriginalURI(nsIURI **aOriginalURI);
423     nsresult SetOriginalURI(nsIURI *aOriginalURI);
424     nsresult GetURI(nsIURI **aURI);
425     nsresult GetOwner(nsISupports **aOwner);
426     nsresult SetOwner(nsISupports *aOwner);
427     nsresult GetNotificationCallbacks(nsIInterfaceRequestor **aNotificationCallbacks);
428     nsresult SetNotificationCallbacks(nsIInterfaceRequestor *aNotificationCallbacks);
429     nsresult GetSecurityInfo(nsISupports **aSecurityInfo);
430     nsresult GetContentType(nsACString *aContentType);
431     nsresult SetContentType(const nsACString *aContentType);
432     nsresult GetContentCharset(nsACString *aContentCharset);
433     nsresult SetContentCharset(const nsACString *aContentCharset);
434     nsresult GetContentLength(PRInt32 *aContentLength);
435     nsresult SetContentLength(PRInt32 aContentLength);
436     nsresult Open(nsIInputStream **_retval);
437     nsresult AsyncOpen(nsIStreamListener *aListener, nsISupports *aContext);
438 }
439
440 [
441     object,
442     uuid(9277fe09-f0cc-4cd9-bbce-581dd94b0260),
443     local
444     /* FROZEN */
445 ]
446 interface nsIHttpChannel : nsIChannel
447 {
448     nsresult GetRequestMethod(nsACString *aRequestMethod);
449     nsresult SetRequestMethod(const nsACString *aRequestMethod);
450     nsresult GetReferrer(nsIURI **aReferrer);
451     nsresult SetReferrer(nsIURI *aReferrer);
452     nsresult GetRequestHeader(const nsACString *aHeader, nsACString *_retval);
453     nsresult SetRequestHeader(const nsACString *aHeader, const nsACString *aValue, PRBool aMerge);
454     nsresult VisitRequestHeaders(nsIHttpHeaderVisitor *aVisitor);
455     nsresult GetAllowPipelining(PRBool *aAllowPipelining);
456     nsresult SetAllowPipelining(PRBool aAllowPipelining);
457     nsresult GetRedirectionLimit(PRUint32 *aRedirectionLimit);
458     nsresult SetRedirectionLimit(PRUint32 aRedirectionLimit);
459     nsresult GetResponseStatus(PRUint32 *aResponseStatus);
460     nsresult GetResponseStatusText(nsACString *aResponseStatusText);
461     nsresult GetRequestSucceeded(PRBool *aRequestSucceeded);
462     nsresult GetResponseHeader(const nsACString *header, nsACString *_retval);
463     nsresult SetResponseHeader(const nsACString *header, const nsACString *value, PRBool merge);
464     nsresult VisitResponseHeaders(nsIHttpHeaderVisitor *aVisitor);
465     nsresult IsNoStoreResponse(PRBool *_retval);
466     nsresult IsNoCacheResponse(PRBool *_retval);
467 }
468
469 [
470     object,
471     uuid(0eb66361-faaa-4e52-8c7e-6c25f11f8e3c),
472     local
473     /* NOT_FROZEN */
474 ]
475 interface nsIHttpChannelInternal : nsISupports
476 {
477     nsresult GetDocumentURI(nsIURI **aDocumentURI);
478     nsresult SetDocumentURI(nsIURI *aDocumentURI);
479     nsresult GetRequestVersion(PRUint32 *major, PRUint32 *minor);
480     nsresult GetResponseVersion(PRUint32 *major, PRUint32 *minor);
481     nsresult SetCookie(const char *aCookieHeader);
482     nsresult SetupFallbackChannel(const char *aFallbackKey);
483     nsresult GetForceAllowThirdPartyCookie(PRBool *aForceAllowThirdPartyCookie);
484     nsresult SetForceAllowThirdPartyCookie(PRBool aForceAllowThirdPartyCookie);
485 }
486
487 [
488     object,
489     uuid(ddf633d8-e9a4-439d-ad88-de636fd9bb75),
490     local
491     /* FROZEN */
492 ]
493 interface nsIUploadChannel : nsISupports
494 {
495     nsresult SetUploadStream(nsIInputStream *aStream, const nsACString *aContentType,
496                              PRInt32 aContentLength);
497     nsresult GetUploadStream(nsIInputStream **aUploadStream);
498 }
499
500 [
501     object,
502     uuid(a6cf90c1-15b3-11d2-932e-00805f8add32),
503     local
504     /* FROZEN */
505 ]
506 interface nsIDOMCSSRule : nsISupports
507 {
508     nsresult GetType(PRUint16 *aType);
509     nsresult GetCssText(nsAString *aCssText);
510     nsresult SetCssText(const nsAString *aCssText);
511     nsresult GetParentStyleSheet(nsIDOMCSSStyleSheet **aParentStyleSheet);
512     nsresult GetParentRule(nsIDOMCSSRule **aParentRule);
513 }
514
515 [
516     object,
517     uuid(a6cf90be-15b3-11d2-932e-00805f8add32),
518     local
519     /* FROZEN */
520 ]
521 interface nsIDOMCSSStyleDeclaration : nsISupports
522 {
523     nsresult GetCssText(nsAString *aCssText);
524     nsresult SetCssText(const nsAString *aCssText);
525     nsresult GetPropertyValue(const nsAString *propertyName, nsAString *_retval);
526     nsresult GetPropertyCSSValue(const nsAString *propertyName, nsIDOMCSSValue **_retval);
527     nsresult RemoveProperty(const nsAString *propertyName, nsAString *_retval);
528     nsresult GetPropertyPriority(const nsAString *propertyName, nsAString *_retval);
529     nsresult SetProperty(const nsAString *propertyName, const nsAString *value,
530                          const nsAString *priority);
531     nsresult GetLength(PRUint32 *aLength);
532     nsresult Item(PRUint32 index, nsAString *_retval);
533     nsresult GetParentRule(nsIDOMCSSRule **aParentRule);
534 }
535
536 [
537     object,
538     uuid(a6cf90c0-15b3-11d2-932e-00805f8add32),
539     local
540     /* FROZEN */
541 ]
542 interface nsIDOMCSSRuleList : nsISupports
543 {
544     nsresult GetLength(PRUint32 *aLength);
545     nsresult Item(PRUint32 index, nsIDOMCSSRule **_retval);
546 }
547
548 [
549     object,
550     uuid(a6cf9080-15b3-11d2-932e-00805f8add32),
551     local
552     /* FROZEN */
553 ]
554 interface nsIDOMStyleSheet : nsISupports
555 {
556     nsresult GetType(nsAString *aType);
557     nsresult GetDisabled(PRBool *aDisabled);
558     nsresult SetDisabled(PRBool aDisabled);
559     nsresult GetOwnerNode(nsIDOMNode **aOwnerNode);
560     nsresult GetParentStyleSheet(nsIDOMStyleSheet **aParentStyleSheet);
561     nsresult GetHref(nsAString *aHref);
562     nsresult GetTitle(nsAString *aTitle);
563     nsresult GetMedia(nsIDOMMediaList **aMedia);
564 }
565
566 [
567     object,
568     uuid(a6cf90c2-15b3-11d2-932e-00805f8add32),
569     local
570     /* FROZEN */
571 ]
572 interface nsIDOMCSSStyleSheet : nsIDOMStyleSheet
573 {
574     nsresult GetOwnerRule(nsIDOMCSSRule **aOwnerRule);
575     nsresult GetCssRules(nsIDOMCSSRuleList **aCssRules);
576     nsresult InsertRule(const nsAString *rule, PRUint32 index, PRUint32 *_retval);
577     nsresult DeleteRule(PRUint32 index);
578 }
579
580 [
581     object,
582     uuid(a6cf9081-15b3-11d2-932e-00805f8add32),
583     local
584     /* FROZEN */
585 ]
586 interface nsIDOMStyleSheetList : nsISupports
587 {
588     nsresult GetLength(PRUint32 *aLength);
589     nsresult Item(PRUint32 index, nsIDOMStyleSheet **_retval);
590 }
591
592 [
593     object,
594     uuid(a6cf907d-15b3-11d2-932e-00805f8add32),
595     local
596     /* FROZEN */
597 ]
598 interface nsIDOMNodeList : nsISupports
599 {
600     nsresult Item(PRUint32 index, nsIDOMNode **_retval);
601     nsresult GetLength(PRUint32 *aLength);
602 }
603
604 [
605     object,
606     uuid(a6cf907c-15b3-11d2-932e-00805f8add32),
607     local
608     /* FROZEN */
609 ]
610 interface nsIDOMNode : nsISupports
611 {
612     enum NSNODETYPE {
613         ELEMENT_NODE = 1,
614         ATTRIBUTE_NODE = 2,
615         TEXT_NODE = 3,
616         CDATA_SELECTION_NODE = 4,
617         ENTITY_REFERENCE_NODE = 5,
618         ENTITY_NODE = 6,
619         PROCESSING_INSTRUCTION_NODE = 7,
620         COMMENT_NODE = 8,
621         DOCUMENT_NODE = 9,
622         DOCUMENT_TYPE_NODE = 10,
623         DOCUMENT_FRAGMENT_NODE = 11,
624         NOTATION_NODE = 12
625     };
626
627     nsresult GetNodeName(nsAString *aNodeName);
628     nsresult GetNodeValue(nsAString *aNodeValue);
629     nsresult SetNodeValue(const nsAString *aNodeValue);
630     nsresult GetNodeType(PRUint16 *aNodeType);
631     nsresult GetParentNode(nsIDOMNode **aParentNode);
632     nsresult GetChildNodes(nsIDOMNodeList **aChildNodes);
633     nsresult GetFirstChild(nsIDOMNode **aFirstChild);
634     nsresult GetLastChild(nsIDOMNode **aLastChild);
635     nsresult GetPreviousSibling(nsIDOMNode **aPreviousSibling);
636     nsresult GetNextSibling(nsIDOMNode **aNextSibling);
637     nsresult GetAttributes(nsIDOMNamedNodeMap **aAttributes);
638     nsresult GetOwnerDocument(nsIDOMDocument **aOwnerDocument);
639     nsresult InsertBefore(nsIDOMNode *newChild, nsIDOMNode *refChild, nsIDOMNode **_retval);
640     nsresult ReplaceChild(nsIDOMNode *newChild, nsIDOMNode *oldChild, nsIDOMNode **_retval);
641     nsresult RemoveChild(nsIDOMNode *oldChild, nsIDOMNode **_retval);
642     nsresult AppendChild(nsIDOMNode *newChild, nsIDOMNode **_retval);
643     nsresult HasChildNodes(PRBool *_retval);
644     nsresult CloneNode(PRBool deep, nsIDOMNode **_retval);
645     nsresult Normalize();
646     nsresult IsSupported(const nsAString *feature, const nsAString *version, PRBool *_retval);
647     nsresult GetNamespaceURI(nsAString *aNamespaceURI);
648     nsresult GetPrefix(nsAString *aPrefix);
649     nsresult SetPrefix(const nsAString *aPrefix);
650     nsresult GetLocalName(nsAString *aLocalName);
651     nsresult HasAttributes(PRBool *_retval);
652 }
653
654 [
655     object,
656     uuid(a6cf9078-15b3-11d2-932e-00805f8add32),
657     local
658     /* FROZEN */
659 ]
660 interface nsIDOMElement : nsIDOMNode
661 {
662     nsresult GetTagName(nsAString *aTagName);
663     nsresult GetAttribute(const nsAString *name, nsAString *_retval);
664     nsresult SetAttribute(const nsAString *name, const nsAString *value);
665     nsresult RemoveAttribute(const nsAString *name);
666     nsresult GetAttributeNode(const nsAString *name, nsIDOMAttr **_retval);
667     nsresult SetAttributeNode(nsIDOMAttr *newAttr, nsIDOMAttr **_retval);
668     nsresult RemoveAttributeNode(nsIDOMAttr *oldAttr, nsIDOMAttr **_retval);
669     nsresult GetElementsByTagName(const nsAString *name, nsIDOMNodeList **_retval);
670     nsresult GetAttributeNS(const nsAString *namespaceURI, const nsAString *localName,
671                             nsAString *_retval);
672     nsresult SetAttributeNS(const nsAString *namespaceURI, const nsAString *qualifiedName,
673                             const nsAString *value);
674     nsresult RemoveAttributeNS(const nsAString *namespaceURI, const nsAString *localName);
675     nsresult GetAttributeNodeNS(const nsAString *namespaceURI, const nsAString *localName,
676                                 nsIDOMAttr **_retval);
677     nsresult SetAttributeNodeNS(nsIDOMAttr *newAttr, nsIDOMAttr **_retval);
678     nsresult GetElementsByTagNameNS(const nsAString *namespaceURI, const nsAString *localName,
679                                     nsIDOMNodeList **_retval);
680     nsresult HasAttribute(const nsAString *name, PRBool *_retval);
681     nsresult HasAttributeNS(const nsAString *namespaceURI, const nsAString *localName,
682                             PRBool *_retval);
683 }
684
685 [
686     object,
687     uuid(99715845-95fc-4a56-aa53-214b65c26e22),
688     local
689     /* FROZEN */
690 ]
691 interface nsIDOMElementCSSInlineStyle : nsISupports
692 {
693     nsresult GetStyle(nsIDOMCSSStyleDeclaration **aStyle);
694 }
695
696 [
697     object,
698     uuid(f0aef489-18c5-4de6-99d5-58b3758b098c),
699     local
700     /* NOT_FROZEN */
701 ]
702 interface nsIDOMNSElement : nsISupports
703 {
704     nsresult GetElementsByClassName(const nsAString *classes, nsIDOMNodeList **_retval);
705     nsresult GetClientRects(nsIDOMClientRectList **_retval);
706     nsresult GetBoundingClientRect(nsIDOMClientRect **_retval);
707     nsresult GetScrollTop(PRInt32 *aScrollTop);
708     nsresult SetScrollTop(PRInt32 aScrollTop);
709     nsresult GetScrollLeft(PRInt32 *aScrollLeft);
710     nsresult SetScrollLeft(PRInt32 aScrollLeft);
711     nsresult GetScrollHeight(PRInt32 *aScrollHeight);
712     nsresult GetScrollWidth(PRInt32 *aScrollWidth);
713     nsresult GetClientTop(PRInt32 *aClientTop);
714     nsresult GetClientLeft(PRInt32 *aClientLeft);
715     nsresult GetClientHeight(PRInt32 *aClientHeight);
716     nsresult GetClientWidth(PRInt32 *aClientWidth);
717     nsresult GetFirstElementChild(nsIDOMElement **aFirstElementChild);
718     nsresult GetLastElementChild(nsIDOMElement **aLastElementChild);
719     nsresult GetPreviousElementSibling(nsIDOMElement **aPreviousElementSibling);
720     nsresult GetNextElementSibling(nsIDOMElement **aNextElementSibling);
721     nsresult GetChildElementCount(PRUint32 *aChildElementCount);
722     nsresult GetChildren(nsIDOMNodeList **aChildren);
723 }
724
725 cpp_quote("#undef GetClassName")
726
727 [
728     object,
729     uuid(a6cf9085-15b3-11d2-932e-00805f8add32),
730     local
731     /* FROZEN */
732 ]
733 interface nsIDOMHTMLElement : nsIDOMElement
734 {
735     nsresult GetId(nsAString *aId);
736     nsresult SetId(const nsAString *aId);
737     nsresult GetTitle(nsAString *aTitle);
738     nsresult SetTitle(const nsAString *aTitle);
739     nsresult GetLang(nsAString *aLang);
740     nsresult SetLang(const nsAString *aLang);
741     nsresult GetDir(nsAString *aDir);
742     nsresult SetDir(const nsAString *aDir);
743     nsresult GetClassName(nsAString *aClassName);
744     nsresult SetClassName(const nsAString *aClassName);
745 }
746
747 [
748     object,
749     uuid(7f142f9a-fba7-4949-93d6-cf08a974ac51),
750     local
751     /* NOT_FROZEN */
752 ]
753 interface nsIDOMNSHTMLElement : nsISupports
754 {
755     nsresult GetOffsetTop(PRInt32 *aOffsetTop);
756     nsresult GetOffsetLeft(PRInt32 *aOffsetLeft);
757     nsresult GetOffsetWidth(PRInt32 *aOffsetWidth);
758     nsresult GetOffsetHeight(PRInt32 *aOffsetHeight);
759     nsresult GetOffsetParent(nsIDOMElement **aOffsetParent);
760     nsresult GetInnerHTML(nsAString *aInnerHTML);
761     nsresult SetInnerHTML(const nsAString *aInnerHTML);
762     nsresult GetTabIndex(PRInt32 *aTabIndex);
763     nsresult SetTabIndex(PRInt32 aTabIndex);
764     nsresult GetContentEditable(nsAString *aContentEditable);
765     nsresult SetContentEditable(const nsAString *aContentEditable);
766     nsresult blur();
767     nsresult focus();
768     nsresult ScrollIntoView(PRBool top);
769     nsresult GetSpellcheck(PRBool *aSpellcheck);
770     nsresult SetSpellcheck(PRBool aSpellcheck);
771 }
772
773 [
774     object,
775     uuid(a6cf9083-15b3-11d2-932e-00805f8add32),
776     local
777     /* FROZEN */
778 ]
779 interface nsIDOMHTMLCollection : nsISupports
780 {
781     nsresult GetLength(PRUint32 *aLength);
782     nsresult Item(PRUint32 index, nsIDOMNode **_retval);
783     nsresult NamedItem(const nsAString *name, nsIDOMNode **_retval);
784 }
785
786 [
787     object,
788     uuid(a6cf9072-15b3-11d2-932e-00805f8add32),
789     local
790     /* FROZEN */
791 ]
792 interface nsIDOMCharacterData : nsIDOMNode
793 {
794     nsresult GetData(nsAString *aData);
795     nsresult SetData(const nsAString *aData);
796     nsresult GetLength(PRUint32 *aLength);
797     nsresult SubstringData(PRUint32 offset, PRUint32 count, nsAString *_retval);
798     nsresult AppendData(const nsAString *arg);
799     nsresult InsertData(PRUint32 offset, const nsAString *arg);
800     nsresult DeleteData(PRUint32 offset, PRUint32 count);
801     nsresult ReplaceData(PRUint32 offset, PRUint32 count, const nsAString *arg);
802 }
803
804 [
805     object,
806     uuid(a6cf9082-15b3-11d2-932e-00805f8add32),
807     local
808     /* FROZEN */
809 ]
810 interface nsIDOMText : nsIDOMCharacterData
811 {
812     nsresult SplitText(PRUint32 offset, nsIDOMText **_retval);
813 }
814
815 [
816     object,
817     uuid(a6cf9073-15b3-11d2-932e-00805f8add32),
818     local
819     /* FROZEN */
820 ]
821 interface nsIDOMComment : nsIDOMCharacterData
822 {
823 }
824
825 [
826     object,
827     uuid(a6cf9076-15b3-11d2-932e-00805f8add32),
828     local
829     /* FROZEN */
830 ]
831 interface nsIDOMDocumentFragment : nsIDOMNode
832 {
833 }
834
835 [
836     object,
837     uuid(f51ebade-8b1a-11d3-aae7-0010830123b4),
838     local
839     /* FROZEN */
840 ]
841 interface nsIDOMAbstractView : nsISupports
842 {
843     nsresult GetDocument(nsIDOMDocumentView **aDocument);
844 }
845
846 [
847     object,
848     uuid(0b9341f3-95d4-4fa4-adcd-e119e0db2889),
849     local
850     /* NOT_FROZEN */
851 ]
852 interface nsIDOMViewCSS : nsIDOMAbstractView
853 {
854     nsresult GetComputedStyle(nsIDOMElement *elt, const nsAString *pseudoElt, nsIDOMCSSStyleDeclaration **_retval);
855 }
856
857 [
858     object,
859     uuid(a6cf9075-15b3-11d2-932e-00805f8add32),
860     local
861     /* FROZEN */
862 ]
863 interface nsIDOMDocument : nsIDOMNode
864 {
865     nsresult GetDoctype(nsIDOMDocumentType **aDoctype);
866     nsresult GetImplementation(nsIDOMDOMImplementation **aImplementation);
867     nsresult GetDocumentElement(nsIDOMElement **aDocumentElement);
868     nsresult CreateElement(const nsAString *tagName, nsIDOMElement **_retval);
869     nsresult CreateDocumentFragment(nsIDOMDocumentFragment **_retval);
870     nsresult CreateTextNode(const nsAString *data, nsIDOMText **_retval);
871     nsresult CreateComment(const nsAString *data, nsIDOMComment **_retval);
872     nsresult CreateCDATASection(const nsAString *data, nsIDOMCDATASection **_retval);
873     nsresult CreateProcessingInstruction(const nsAString *target, const nsAString *data,
874                                          nsIDOMProcessingInstruction **_retval);
875     nsresult CreateAttribute(const nsAString *name, nsIDOMAttr **_retval);
876     nsresult CreateEntityReference(const nsAString *name, nsIDOMEntityReference **_retval);
877     nsresult GetElementsByTagName(const nsAString *tagname, nsIDOMNodeList **_retval);
878     nsresult ImportNode(nsIDOMNode *importedNode, PRBool deep, nsIDOMNode **_retval);
879     nsresult CreateElementNS(const nsAString *namespaceURI, const nsAString *qualifiedName,
880                              nsIDOMElement **_retval);
881     nsresult CreateAttributeNS(const nsAString *namespaceURI, const nsAString *qualifiedName,
882                                nsIDOMAttr **_retval);
883     nsresult GetElementsByTagNameNS(const nsAString *namespaceURI, const nsAString *localName,
884                                     nsIDOMNodeList **_retval);
885     nsresult GetElementById(const nsAString *elementId, nsIDOMElement **_retval);
886 }
887
888 [
889     object,
890     uuid(09a439ad-4079-46d5-a050-4d7015d1a108),
891     local
892     /* NOT_FROZEN */
893 ]
894 interface nsIDOMNSDocument : nsISupports
895 {
896     nsresult GetCharacterSet(nsAString *aCharacterSet);
897     nsresult GetDir(nsAString *aDir);
898     nsresult SetDir(const nsAString *aDir);
899     nsresult GetLocation(nsIDOMLocation **aLocation);
900     nsresult GetTitle(nsAString *aTitle);
901     nsresult SetTitle(const nsAString *aTitle);
902     nsresult GetContentType(nsAString *aContentType);
903     nsresult GetReadyState(nsAString *aReadyState);
904     nsresult GetLastModified(nsAString *aLastModified);
905     nsresult GetReferrer(nsAString *aReferrer);
906     nsresult HasFocus(PRBool *_retval);
907     nsresult GetActiveElement(nsIDOMElement **aActiveElement);
908     nsresult GetElementsByClassName(const nsAString *classes, nsIDOMNodeList **_retval);
909     nsresult ElementFromPoint(PRInt32 x, PRInt32 y, nsIDOMElement **_retval);
910
911     /* Wine extensions */
912     nsresult WineAddObserver(nsIDocumentObserver *aObserver);
913     nsresult WineRemoveObserver(nsIDocumentObserver *aObserver);
914     nsresult WineAddScriptRunner(nsIRunnable *aRunnable);
915 }
916
917 [
918     object,
919     uuid(a6cf9084-15b3-11d2-932e-00805f8add32),
920     local
921     /* FROZEN */
922 ]
923 interface nsIDOMHTMLDocument : nsIDOMDocument
924 {
925     nsresult GetTitle(nsAString *aTitle);
926     nsresult SetTitle(const nsAString *aTitle);
927     nsresult GetReferrer(nsAString *aReferrer);
928     nsresult GetDomain(nsAString *aDomain);
929     nsresult GetURL(nsAString *aURL);
930     nsresult GetBody(nsIDOMHTMLElement **aBody);
931     nsresult SetBody(nsIDOMHTMLElement *aBody);
932     nsresult GetImages(nsIDOMHTMLCollection **aImages);
933     nsresult GetApplets(nsIDOMHTMLCollection **aApplets);
934     nsresult GetLinks(nsIDOMHTMLCollection **aLinks);
935     nsresult GetForms(nsIDOMHTMLCollection **aForms);
936     nsresult GetAnchors(nsIDOMHTMLCollection **aAnchors);
937     nsresult GetCookie(nsAString *aCookie);
938     nsresult SetCookie(const nsAString *aCookie);
939     nsresult Open();
940     nsresult Close();
941     nsresult Write(const nsAString *text);
942     nsresult Writeln(const nsAString *text);
943     nsresult GetElementsByName(const nsAString *elementName, nsIDOMNodeList **_retval);
944 }
945
946 [
947     object,
948     uuid(79beb289-3644-4b54-9432-9fb993945629),
949     local
950     /* NOT_FROZEN */
951 ]
952 interface nsIDOMNSHTMLDocument : nsISupports
953 {
954     nsresult GetWidth(PRInt32 *aWidth);
955     nsresult GetHeight(PRInt32 *aHeight);
956     nsresult GetAlinkColor(nsAString *aAlinkColor);
957     nsresult SetAlinkColor(const nsAString *aAlinkColor);
958     nsresult GetLinkColor(nsAString *aLinkColor);
959     nsresult SetLinkColor(const nsAString *aLinkColor);
960     nsresult GetVlinkColor(nsAString *aVlinkColor);
961     nsresult SetVlinkColor(const nsAString *aVlinkColor);
962     nsresult GetBgColor(nsAString *aBgColor);
963     nsresult SetBgColor(const nsAString *aBgColor);
964     nsresult GetFgColor(nsAString *aFgColor);
965     nsresult SetFgColor(const nsAString *aFgColor);
966     nsresult GetDomain(nsAString *aDomain);
967     nsresult SetDomain(const nsAString *aDomain);
968     nsresult GetEmbeds(nsIDOMHTMLCollection **aEmbeds);
969     nsresult GetSelection(nsAString *_retval);
970     nsresult Open(nsACString *aContentType, PRBool aReplace, nsIDOMDocument **_retval);
971     nsresult Write();
972     nsresult Writeln();
973     nsresult Clear();
974     nsresult CaptureEvents(PRInt32 eventFlags);
975     nsresult ReleaseEvents(PRInt32 eventFlags);
976     nsresult RouteEvent(nsIDOMEvent *evt);
977     nsresult GetCompatMode(nsAString *aCompatMode);
978     nsresult GetPlugins(nsIDOMHTMLCollection **aPlugins);
979     nsresult GetDesignMode(nsAString *aDesignMode);
980     nsresult SetDesignMode(const nsAString *aDesignMode);
981     nsresult ExecCommand(const nsAString *commandID, PRBool doShowUI, const nsAString *value, PRBool *_retval);
982     nsresult ExecCommandShowHelp(const nsAString *commandID, PRBool *_retval);
983     nsresult QueryCommandEnabled(const nsAString *commandID, PRBool *_retval);
984     nsresult QueryCommandIndeterm(const nsAString *commandID, PRBool *_retval);
985     nsresult QueryCommandState(const nsAString *commandID, PRBool *_retval);
986     nsresult QueryCommandSupported(const nsAString *commandID, PRBool *_retval);
987     nsresult QueryCommandText(const nsAString *commandID, nsAString *_retval);
988     nsresult QueryCommandValue(const nsAString *commandID, nsAString *_retval);
989 }
990
991 [
992     object,
993     uuid(3d9f4973-dd2e-48f5-b5f7-2634e09eadd9),
994     local
995     /* FROZEN */
996 ]
997 interface nsIDOMDocumentStyle : nsISupports
998 {
999     nsresult GetStyleSheets(nsIDOMStyleSheetList **aStyleSheets);
1000 }
1001
1002 [
1003     object,
1004     uuid(1acdb2ba-1dd2-11b2-95bc-9542495d2569),
1005     local
1006     /* FROZEN */
1007 ]
1008 interface nsIDOMDocumentView : nsISupports
1009 {
1010     nsresult GetDefaultView(nsIDOMAbstractView **aDefaultView);
1011 }
1012
1013 [
1014     object,
1015     uuid(46b91d66-28e2-11d4-ab1e-0010830123b4),
1016     local
1017     /* FROZEN */
1018 ]
1019 interface nsIDOMDocumentEvent : nsISupports
1020 {
1021 cpp_quote("#undef CreateEvent")
1022     nsresult CreateEvent(const nsAString *eventType, nsIDOMEvent **_retval);
1023 }
1024
1025 [
1026     object,
1027     uuid(a6cf90ce-15b3-11d2-932e-00805f8add32),
1028     local
1029     /* FROZEN */
1030 ]
1031 interface nsIDOMRange : nsISupports
1032 {
1033     enum {
1034         NS_START_TO_START,
1035         NS_START_TO_END,
1036         NS_END_TO_END,
1037         NS_END_TO_START
1038     };
1039
1040     nsresult GetStartContainer(nsIDOMNode **aStartContainer);
1041     nsresult GetStartOffset(PRInt32 *aStartOffset);
1042     nsresult GetEndContainer(nsIDOMNode **aEndContainer);
1043     nsresult GetEndOffset(PRInt32 *aEndOffset);
1044     nsresult GetCollapsed(PRBool *aCollapsed);
1045     nsresult GetCommonAncestorContainer(nsIDOMNode **aCommonAncestorContainer);
1046     nsresult SetStart(nsIDOMNode *refNode, PRInt32 offset);
1047     nsresult SetEnd(nsIDOMNode *refNode, PRInt32 offset);
1048     nsresult SetStartBefore(nsIDOMNode *refNode);
1049     nsresult SetStartAfter(nsIDOMNode *refNode);
1050     nsresult SetEndBefore(nsIDOMNode *refNode);
1051     nsresult SetEndAfter(nsIDOMNode *refNode);
1052     nsresult Collapse(PRBool toStart);
1053     nsresult SelectNode(nsIDOMNode *refNode);
1054     nsresult SelectNodeContents(nsIDOMNode *refNode);
1055     nsresult CompareBoundaryPoints(PRUint16 how, nsIDOMRange *sourceRange, PRInt16 *_retval);
1056     nsresult DeleteContents();
1057     nsresult ExtractContents(nsIDOMDocumentFragment **_retval);
1058     nsresult CloneContents(nsIDOMDocumentFragment **_retval);
1059     nsresult InsertNode(nsIDOMNode *newNode);
1060     nsresult SurroundContents(nsIDOMNode *newParent);
1061     nsresult CloneRange(nsIDOMRange **_retval);
1062     nsresult ToString(nsAString *_retval);
1063     nsresult Detach();
1064 }
1065
1066 [
1067     object,
1068     uuid(59188642-23b4-41d6-bde1-302c3906d1f0),
1069     local
1070     /* NOT_FROZEN */
1071 ]
1072 interface nsIDOMNSRange : nsISupports
1073 {
1074     nsresult CreateContextualFragment([in] const nsAString *fragment, [out] nsIDOMDocumentFragment **_retval);
1075     nsresult IsPointInRange([in] nsIDOMNode *parent, [in] PRInt32 offset, [out] PRBool *_retval);
1076     nsresult ComparePoint([in] nsIDOMNode *parent, [in] PRInt32 offset, [out] PRInt16 *_retval);
1077 }
1078
1079
1080 [
1081     object,
1082     uuid(7b9badc6-c9bc-447a-8670-dbd195aed24b),
1083     local
1084     /* FROZEN */
1085 ]
1086 interface nsIDOMDocumentRange : nsISupports
1087 {
1088     nsresult CreateRange(nsIDOMRange **_retval);
1089 }
1090
1091 [
1092     object,
1093     uuid(b2c7ed59-8634-4352-9e37-5484c8b6e4e1),
1094     local
1095     /* FROZEN */
1096 ]
1097 interface nsISelection : nsISupports
1098 {
1099     nsresult GetAnchorNode(nsIDOMNode **aAnchorNode);
1100     nsresult GetAnchorOffset(PRInt32 *aAnchorOffset);
1101     nsresult GetFocusNode(nsIDOMNode **aFocusNode);
1102     nsresult GetFocusOffset(PRInt32 *aFocusOffset);
1103     nsresult GetIsCollapsed(PRBool *aIsCollapsed);
1104     nsresult GetRangeCount(PRInt32 *aRangeCount);
1105     nsresult GetRangeAt(PRInt32 index, nsIDOMRange **_retval);
1106     nsresult Collapse(nsIDOMNode *parentNode, PRInt32 offset);
1107     nsresult Extend(nsIDOMNode *parentNode, PRInt32 offset);
1108     nsresult CollapseToStart();
1109     nsresult CollapseToEnd();
1110     nsresult ContainsNode(nsIDOMNode *node, PRBool entirelyContained, PRBool *_retval);
1111     nsresult SelectAllChildren(nsIDOMNode *parentNode);
1112     nsresult AddRange(nsIDOMRange *range);
1113     nsresult RemoveRange(nsIDOMRange *range);
1114     nsresult RemoveAllRanges();
1115     nsresult DeleteFromDocument();
1116     nsresult SelectionLanguageChange(PRBool langRTL);
1117     nsresult ToString(PRUnichar **_retval);
1118 }
1119
1120 [
1121     object,
1122     uuid(a6cf906f-15b3-11d2-932e-00805f8add32),
1123     local
1124     /* FROZEN */
1125 ]
1126 interface nsIDOMWindowCollection : nsISupports
1127 {
1128     nsresult GetLength(PRUint32 *aLength);
1129     nsresult Item(PRUint32 index, nsIDOMWindow **_retval);
1130     nsresult NamedItem(const nsAString *name, nsIDOMWindow **_retval);
1131 }
1132
1133 [
1134     object,
1135     uuid(a6cf906b-15b3-11d2-932e-00805f8add32),
1136     local
1137     /* FROZEN */
1138 ]
1139 interface nsIDOMWindow : nsISupports
1140 {
1141     nsresult GetDocument(nsIDOMDocument **aDocument);
1142     nsresult GetParent(nsIDOMWindow **aParent);
1143     nsresult GetTop(nsIDOMWindow **aTop);
1144     nsresult GetScrollbars(nsIDOMBarProp **aScrollbars);
1145     nsresult GetFrames(nsIDOMWindowCollection **aFrames);
1146     nsresult GetName(nsAString *aName);
1147     nsresult SetName(const nsAString *aName);
1148     nsresult GetTextZoom(float *aTextZoom);
1149     nsresult SetTextZoom(float aTextZoom);
1150     nsresult GetScrollX(PRInt32 *aScrollX);
1151     nsresult GetScrollY(PRInt32 *aScrollY);
1152     nsresult ScrollTo(PRInt32 xScroll, PRInt32 yScroll);
1153     nsresult ScrollBy(PRInt32 xScrollDif, PRInt32 yScrollDif);
1154     nsresult GetSelection(nsISelection **_retval);
1155     nsresult ScrollByLines(PRInt32 numLines);
1156     nsresult ScrollByPages(PRInt32 numPages);
1157     nsresult SizeToContent();
1158 }
1159
1160 [
1161     object,
1162     uuid(a6cf908e-15b3-11d2-932e-00805f8add32),
1163     local
1164     /* FROZEN */
1165 ]
1166 interface nsIDOMHTMLBodyElement : nsIDOMHTMLElement
1167 {
1168     nsresult GetALink(nsAString *aALink);
1169     nsresult SetALink(const nsAString *aALink);
1170     nsresult GetBackground(nsAString *aBackground);
1171     nsresult SetBackground(const nsAString *aBackground);
1172     nsresult GetBgColor(nsAString *aBgColor);
1173     nsresult SetBgColor(const nsAString *aBgColor);
1174     nsresult GetLink(nsAString *aLink);
1175     nsresult SetLink(const nsAString *aLink);
1176     nsresult GetText(nsAString *aText);
1177     nsresult SetText(const nsAString *aText);
1178     nsresult GetVLink(nsAString *aVLink);
1179     nsresult SetVLink(const nsAString *aVLink);
1180 }
1181
1182 [
1183     object,
1184     uuid(a6cf9093-15b3-11d2-932e-00805f8add32),
1185     local
1186     /* FROZEN */
1187 ]
1188 interface nsIDOMHTMLInputElement : nsIDOMHTMLElement
1189 {
1190     nsresult GetDefaultValue(nsAString *aDefaultValue);
1191     nsresult SetDefaultValue(const nsAString *aDefaultValue);
1192     nsresult GetDefaultChecked(PRBool *aDefaultChecked);
1193     nsresult SetDefaultChecked(PRBool aDefaultChecked);
1194     nsresult GetForm(nsIDOMHTMLFormElement **aForm);
1195     nsresult GetAccept(nsAString *aAccept);
1196     nsresult SetAccept(const nsAString *aAccept);
1197     nsresult GetAccessKey(nsAString *aAccessKey);
1198     nsresult SetAccessKey(const nsAString *aAccessKey);
1199     nsresult GetAlign(nsAString *aAlign);
1200     nsresult SetAlign(const nsAString *aAlign);
1201     nsresult GetAlt(nsAString *aAlt);
1202     nsresult SetAlt(const nsAString *aAlt);
1203     nsresult GetChecked(PRBool *aChecked);
1204     nsresult SetChecked(PRBool aChecked);
1205     nsresult GetDisabled(PRBool *aDisabled);
1206     nsresult SetDisabled(PRBool aDisabled);
1207     nsresult GetMaxLength(PRInt32 *aMaxLength);
1208     nsresult SetMaxLength(PRInt32 aMaxLength);
1209     nsresult GetName(nsAString *aName);
1210     nsresult SetName(const nsAString *aName);
1211     nsresult GetReadOnly(PRBool *aReadOnly);
1212     nsresult SetReadOnly(PRBool aReadOnly);
1213     nsresult GetSize(PRUint32 *aSize);
1214     nsresult SetSize(PRUint32 aSize);
1215     nsresult GetSrc(nsAString *aSrc);
1216     nsresult SetSrc(const nsAString *aSrc);
1217     nsresult GetTabIndex(PRInt32 *aTabIndex);
1218     nsresult SetTabIndex(PRInt32 aTabIndex);
1219     nsresult GetType(nsAString *aType);
1220     nsresult SetType(const nsAString *aType);
1221     nsresult GetUseMap(nsAString *aUseMap);
1222     nsresult SetUseMap(const nsAString *aUseMap);
1223     nsresult GetValue(nsAString *aValue);
1224     nsresult SetValue(const nsAString *aValue);
1225     nsresult Blur();
1226     nsresult Focus();
1227     nsresult Select();
1228     nsresult Click();
1229 }
1230
1231 [
1232     object,
1233     uuid(a6cf9092-15b3-11d2-932e-00805f8add32),
1234     local
1235     /* FROZEN */
1236 ]
1237 interface nsIDOMHTMLOptionElement : nsIDOMHTMLElement
1238 {
1239     nsresult GetForm(nsIDOMHTMLFormElement **aForm);
1240     nsresult GetDefaultSelected(PRBool *aDefaultSelected);
1241     nsresult SetDefaultSelected(PRBool aDefaultSelected);
1242     nsresult GetText(nsAString *aText);
1243     nsresult GetIndex(PRInt32 *aIndex);
1244     nsresult GetDisabled(PRBool *aDisabled);
1245     nsresult SetDisabled(PRBool aDisabled);
1246     nsresult GetLabel(nsAString *aLabel);
1247     nsresult SetLabel(const nsAString *aLabel);
1248     nsresult GetSelected(PRBool *aSelected);
1249     nsresult SetSelected(PRBool aSelected);
1250     nsresult GetValue(nsAString *aValue);
1251     nsresult SetValue(const nsAString *aValue);
1252 }
1253
1254 [
1255     object,
1256     uuid(a6cf9090-15b3-11d2-932e-00805f8add32),
1257     local
1258     /* FROZEN */
1259 ]
1260 interface nsIDOMHTMLSelectElement : nsIDOMHTMLElement
1261 {
1262     nsresult GetType(nsAString *aType);
1263     nsresult GetSelectedIndex(PRInt32 *aSelectedIndex);
1264     nsresult SetSelectedIndex(PRInt32 aSelectedIndex);
1265     nsresult GetValue(nsAString *aValue);
1266     nsresult SetValue(const nsAString *aValue);
1267     nsresult GetLength(PRUint32 *aLength);
1268     nsresult SetLength(PRUint32 aLength);
1269     nsresult GetForm(nsIDOMHTMLFormElement **aForm);
1270     nsresult GetOptions(nsIDOMHTMLOptionsCollection **aOptions);
1271     nsresult GetDisabled(PRBool *aDisabled);
1272     nsresult SetDisabled(PRBool aDisabled);
1273     nsresult GetMultiple(PRBool *aMultiple);
1274     nsresult SetMultiple(PRBool aMultiple);
1275     nsresult GetName(nsAString *aName);
1276     nsresult SetName(const nsAString *aName);
1277     nsresult GetSize(PRInt32 *aSize);
1278     nsresult SetSize(PRInt32 aSize);
1279     nsresult GetTabIndex(PRInt32 *aTabIndex);
1280     nsresult SetTabIndex(PRInt32 aTabIndex);
1281     nsresult Add(nsIDOMHTMLElement *element, nsIDOMHTMLElement *before);
1282     nsresult Remove(PRInt32 index);
1283     nsresult Blur();
1284     nsresult Focus();
1285 }
1286
1287 [
1288     object,
1289     uuid(a6cf9094-15b3-11d2-932e-00805f8add32),
1290     local
1291     /* FROZEN */
1292 ]
1293 interface nsIDOMHTMLTextAreaElement : nsIDOMHTMLElement
1294 {
1295     nsresult GetDefaultValue(nsAString *aDefaultValue);
1296     nsresult SetDefaultValue(const nsAString *aDefaultValue);
1297     nsresult GetForm(nsIDOMHTMLFormElement **aForm);
1298     nsresult GetAccessKey(nsAString *aAccessKey);
1299     nsresult SetAccessKey(const nsAString *aAccessKey);
1300     nsresult GetCols(PRInt32 *aCols);
1301     nsresult SetCols(PRInt32 aCols);
1302     nsresult GetDisabled(PRBool *aDisabled);
1303     nsresult SetDisabled(PRBool aDisabled);
1304     nsresult GetName(nsAString *aName);
1305     nsresult SetName(const nsAString *aName);
1306     nsresult GetReadOnly(PRBool *aReadOnly);
1307     nsresult SetReadOnly(PRBool aReadOnly);
1308     nsresult GetRows(PRInt32 *aRows);
1309     nsresult SetRows(PRInt32 aRows);
1310     nsresult GetTabIndex(PRInt32 *aTabIndex);
1311     nsresult SetTabIndex(PRInt32 aTabIndex);
1312     nsresult GetType(nsAString *aType);
1313     nsresult GetValue(nsAString *aValue);
1314     nsresult SetValue(const nsAString *aValue);
1315     nsresult Blur();
1316     nsresult Focus();
1317     nsresult Select();
1318 }
1319
1320 [
1321     object,
1322     uuid(a6cf90b1-15b3-11d2-932e-00805f8add32),
1323     local
1324     /* FROZEN */
1325 ]
1326 interface nsIDOMHTMLScriptElement : nsIDOMHTMLElement
1327 {
1328     nsresult GetText(nsAString *aText);
1329     nsresult SetText(const nsAString *aText);
1330     nsresult GetHtmlFor(nsAString *aHtmlFor);
1331     nsresult SetHtmlFor(const nsAString *aHtmlFor);
1332     nsresult GetEvent(nsAString *aEvent);
1333     nsresult SetEvent(const nsAString *aEvent);
1334     nsresult GetCharset(nsAString *aCharset);
1335     nsresult SetCharset(const nsAString *aCharset);
1336     nsresult GetDefer(PRBool *aDefer);
1337     nsresult SetDefer(PRBool aDefer);
1338     nsresult GetSrc(nsAString *aSrc);
1339     nsresult SetSrc(const nsAString *aSrc);
1340     nsresult GetType(nsAString *aType);
1341     nsresult SetType(const nsAString *aType);
1342 }
1343
1344 [
1345     object,
1346     uuid(a6cf90ab-15b3-11d2-932e-00805f8add32),
1347     local
1348     /* FROZEN */
1349 ]
1350 interface nsIDOMHTMLImageElement : nsIDOMHTMLElement
1351 {
1352     nsresult GetName(nsAString *aName);
1353     nsresult SetName(const nsAString *aName);
1354     nsresult GetAlign(nsAString *aAlign);
1355     nsresult SetAlign(const nsAString *aAlign);
1356     nsresult GetAlt(nsAString *aAlt);
1357     nsresult SetAlt(const nsAString *aAlt);
1358     nsresult GetBorder(nsAString *aBorder);
1359     nsresult SetBorder(const nsAString *aBorder);
1360     nsresult GetHeight(PRInt32 *aHeight);
1361     nsresult SetHeight(PRInt32 aHeight);
1362     nsresult GetHspace(PRInt32 *aHspace);
1363     nsresult SetHspace(PRInt32 aHspace);
1364     nsresult GetIsMap(PRBool *aIsMap);
1365     nsresult SetIsMap(PRBool aIsMap);
1366     nsresult GetLongDesc(nsAString *aLongDesc);
1367     nsresult SetLongDesc(const nsAString *aLongDesc);
1368     nsresult GetSrc(nsAString *aSrc);
1369     nsresult SetSrc(const nsAString *aSrc);
1370     nsresult GetUseMap(nsAString *aUseMap);
1371     nsresult SetUseMap(const nsAString *aUseMap);
1372     nsresult GetVspace(PRInt32 *aVspace);
1373     nsresult SetVspace(PRInt32 aVspace);
1374     nsresult GetWidth(PRInt32 *aWidth);
1375     nsresult SetWidth(PRInt32 aWidth);
1376 }
1377
1378 [
1379     object,
1380     uuid(a6cf90aa-15b3-11d2-932e-00805f8add32),
1381     local
1382     /* FROZEN */
1383 ]
1384 interface nsIDOMHTMLAnchorElement : nsIDOMHTMLElement
1385 {
1386     nsresult GetAccessKey(nsAString *aAccessKey);
1387     nsresult SetAccessKey(const nsAString *aAccessKey);
1388     nsresult GetCharset(nsAString *aCharset);
1389     nsresult SetCharset(const nsAString *aCharset);
1390     nsresult GetCoords(nsAString *aCoords);
1391     nsresult SetCoords(const nsAString *aCoords);
1392     nsresult GetHref(nsAString *aHref);
1393     nsresult SetHref(const nsAString *aHref);
1394     nsresult GetHreflang(nsAString *aHreflang);
1395     nsresult SetHreflang(const nsAString *aHreflang);
1396     nsresult GetName(nsAString *aName);
1397     nsresult SetName(const nsAString *aName);
1398     nsresult GetRel(nsAString *aRel);
1399     nsresult SetRel(const nsAString *aRel);
1400     nsresult GetRev(nsAString *aRev);
1401     nsresult SetRev(const nsAString *aRev);
1402     nsresult GetShape(nsAString *aShape);
1403     nsresult SetShape(const nsAString *aShape);
1404     nsresult GetTabIndex(PRInt32 *aTabIndex);
1405     nsresult SetTabIndex(PRInt32 aTabIndex);
1406     nsresult GetTarget(nsAString *aTarget);
1407     nsresult SetTarget(const nsAString *aTarget);
1408     nsresult GetType(nsAString *aType);
1409     nsresult SetType(const nsAString *aType);
1410     nsresult Blur();
1411     nsresult Focus();
1412 }
1413
1414 [
1415     object,
1416     uuid(a6cf90b2-15b3-11d2-932e-00805f8add32),
1417     local
1418     /* FROZEN */
1419 ]
1420 interface nsIDOMHTMLTableElement : nsIDOMHTMLElement
1421 {
1422     nsresult GetCaption(nsIDOMHTMLTableCaptionElement **aCaption);
1423     nsresult SetCaption(nsIDOMHTMLTableCaptionElement *aCaption);
1424     nsresult GetTHead(nsIDOMHTMLTableSectionElement **aTHead);
1425     nsresult SetTHead(nsIDOMHTMLTableSectionElement *aTHead);
1426     nsresult GetTFoot(nsIDOMHTMLTableSectionElement **aTFoot);
1427     nsresult SetTFoot(nsIDOMHTMLTableSectionElement *aTFoot);
1428     nsresult GetRows(nsIDOMHTMLCollection **aRows);
1429     nsresult GetTBodies(nsIDOMHTMLCollection **aTBodies);
1430     nsresult GetAlign(nsAString *aAlign);
1431     nsresult SetAlign(const nsAString *aAlign);
1432     nsresult GetBgColor(nsAString *aBgColor);
1433     nsresult SetBgColor(const nsAString *aBgColor);
1434     nsresult GetBorder(nsAString *aBorder);
1435     nsresult SetBorder(const nsAString *aBorder);
1436     nsresult GetCellPadding(nsAString *aCellPadding);
1437     nsresult SetCellPadding(const nsAString *aCellPadding);
1438     nsresult GetCellSpacing(nsAString *aCellSpacing);
1439     nsresult SetCellSpacing(const nsAString *aCellSpacing);
1440     nsresult GetFrame(nsAString *aFrame);
1441     nsresult SetFrame(const nsAString *aFrame);
1442     nsresult GetRules(nsAString *aRules);
1443     nsresult SetRules(const nsAString *aRules);
1444     nsresult GetSummary(nsAString *aSummary);
1445     nsresult SetSummary(const nsAString *aSummary);
1446     nsresult GetWidth(nsAString *aWidth);
1447     nsresult SetWidth(const nsAString *aWidth);
1448     nsresult CreateTHead(nsIDOMHTMLElement **_retval);
1449     nsresult DeleteTHead();
1450     nsresult CreateTFoot(nsIDOMHTMLElement **_retval);
1451     nsresult DeleteTFoot();
1452     nsresult CreateCaption(nsIDOMHTMLElement **_retval);
1453     nsresult DeleteCaption();
1454     nsresult InsertRow(PRInt32 index, nsIDOMHTMLElement **_retval);
1455     nsresult DeleteRow(PRInt32 index);
1456 }
1457
1458 [
1459     object,
1460     uuid(a6cf90b6-15b3-11d2-932e-00805f8add32),
1461     local
1462     /* FROZEN */
1463 ]
1464 interface nsIDOMHTMLTableRowElement : nsIDOMHTMLElement
1465 {
1466     nsresult GetRowIndex(PRInt32 *aRowIndex);
1467     nsresult GetSectionRowIndex(PRInt32 *aSectionRowIndex);
1468     nsresult GetCells(nsIDOMHTMLCollection **aCells);
1469     nsresult GetAlign(nsAString *aAlign);
1470     nsresult SetAlign(const nsAString *aAlign);
1471     nsresult GetBgColor(nsAString *aBgColor);
1472     nsresult SetBgColor(const nsAString *aBgColor);
1473     nsresult GetCh(nsAString *aCh);
1474     nsresult SetCh(const nsAString *aCh);
1475     nsresult GetChOff(nsAString *aChOff);
1476     nsresult SetChOff(const nsAString *aChOff);
1477     nsresult GetVAlign(nsAString *aVAlign);
1478     nsresult SetVAlign(const nsAString *aVAlign);
1479     nsresult InsertCell(PRInt32 index, nsIDOMHTMLElement **_retval);
1480     nsresult DeleteCell(PRInt32 index);
1481 }
1482
1483 [
1484     object,
1485     uuid(a6cf90ba-15b3-11d2-932e-00805f8add32),
1486     local
1487     /* FROZEN */
1488 ]
1489 interface nsIDOMHTMLIFrameElement : nsIDOMHTMLElement
1490 {
1491     nsresult GetAlign(nsAString *aAlign);
1492     nsresult SetAlign(const nsAString *aAlign);
1493     nsresult GetFrameBorder(nsAString *aFrameBorder);
1494     nsresult SetFrameBorder(const nsAString *aFrameBorder);
1495     nsresult GetHeight(nsAString *aHeight);
1496     nsresult SetHeight(const nsAString *aHeight);
1497     nsresult GetLongDesc(nsAString *aLongDesc);
1498     nsresult SetLongDesc(const nsAString *aLongDesc);
1499     nsresult GetMarginHeight(nsAString *aMarginHeight);
1500     nsresult SetMarginHeight(const nsAString *aMarginHeight);
1501     nsresult GetMarginWidth(nsAString *aMarginWidth);
1502     nsresult SetMarginWidth(const nsAString *aMarginWidth);
1503     nsresult GetName(nsAString *aName);
1504     nsresult SetName(const nsAString *aName);
1505     nsresult GetScrolling(nsAString *aScrolling);
1506     nsresult SetScrolling(const nsAString *aScrolling);
1507     nsresult GetSrc(nsAString *aSrc);
1508     nsresult SetSrc(const nsAString *aSrc);
1509     nsresult GetWidth(nsAString *aWidth);
1510     nsresult SetWidth(const nsAString *aWidth);
1511     nsresult GetContentDocument(nsIDOMDocument **aContentDocument);
1512 }
1513
1514 [
1515     object,
1516     uuid(94928ab3-8b63-11d3-989d-001083010e9b),
1517     local
1518     /* FROZEN */
1519 ]
1520 interface nsIURIContentListener : nsISupports
1521 {
1522     nsresult OnStartURIOpen(nsIURI *aURI, PRBool *_retval);
1523     nsresult DoContent(const char *aContentType, PRBool aIsContentPreferred, nsIRequest *aRequest,
1524         nsIStreamListener **aContentHandler, PRBool *_retval);
1525     nsresult IsPreferred(const char *aContentType, char **aDesiredContentType, PRBool *_retval);
1526     nsresult CanHandleContent(const char *aContentType, PRBool aIsContentPreferred,
1527         char **aDesiredContentType, PRBool *_retval);
1528     nsresult GetLoadCookie(nsISupports **aLoadCookie);
1529     nsresult SetLoadCookie(nsISupports *aLoadCookie);
1530     nsresult GetParentContentListener(nsIURIContentListener **aParentContentListener);
1531     nsresult SetParentContentListener(nsIURIContentListener *aParentContentListener);
1532 }
1533
1534 [
1535     object,
1536     uuid(44b78386-1dd2-11b2-9ad2-e4eee2ca1916),
1537     local
1538     /* FROZEN */
1539 ]
1540 interface nsITooltipListener : nsISupports
1541 {
1542     nsresult OnShowTooltip(PRInt32 aXCoords, PRInt32 aYCoords, const PRUnichar *aTipText);
1543     nsresult OnHideTooltip();
1544 }
1545
1546 [
1547     object,
1548     uuid(69e5df00-7b8b-11d3-af61-00a024ffc08c),
1549     local
1550     /* FROZEN */
1551 ]
1552 interface nsIWebBrowser : nsISupports
1553 {
1554     nsresult AddWebBrowserListener(nsIWeakReference *aListener, const nsIID *aIID);
1555     nsresult RemoveWebBrowserListener(nsIWeakReference *aListener, const nsIID *aIID);
1556     nsresult GetContainerWindow(nsIWebBrowserChrome **aContainerWindow);
1557     nsresult SetContainerWindow(nsIWebBrowserChrome *aContainerWindow);
1558     nsresult GetParentURIContentListener(nsIURIContentListener **aParentURIContentListener);
1559     nsresult SetParentURIContentListener(nsIURIContentListener *aParentURIContentListener);
1560     nsresult GetContentDOMWindow(nsIDOMWindow **aContentDOMWindow);
1561 }
1562
1563 cpp_quote("#define SETUP_ALLOW_JAVASCRIPT  2")
1564 cpp_quote("#define SETUP_IS_CHROME_WRAPPER 7")
1565
1566 [
1567     object,
1568     uuid(f15398a0-8018-11d3-af70-00a024ffc08c),
1569     local
1570     /* FROZEN */
1571 ]
1572 interface nsIWebBrowserSetup : nsISupports
1573 {
1574     nsresult SetProperty(PRUint32 aId, PRUint32 aValue);
1575 }
1576
1577 typedef void* nativeWindow;
1578
1579 [
1580     object,
1581     uuid(046bc8a0-8015-11d3-af70-00a024ffc08c),
1582     local
1583     /* NOT_FROZEN */
1584 ]
1585 interface nsIBaseWindow : nsISupports
1586 {
1587     nsresult InitWindow(nativeWindow parentNativeWindow, nsIWidget *parentWidget, PRInt32 x,
1588             PRInt32 y, PRInt32 cx, PRInt32 cy);
1589     nsresult Create();
1590     nsresult Destroy();
1591     nsresult SetPosition(PRInt32 x, PRInt32 y);
1592     nsresult GetPosition(PRInt32 *x, PRInt32 *y);
1593     nsresult SetSize(PRInt32 cx, PRInt32 cy, PRBool fRepaint);
1594     nsresult GetSize(PRInt32 *cx, PRInt32 *cy);
1595     nsresult SetPositionAndSize(PRInt32 x, PRInt32 y, PRInt32 cx, PRInt32 cy, PRBool fRepaint);
1596     nsresult GetPositionAndSize(PRInt32 *x, PRInt32 *y, PRInt32 *cx, PRInt32 *cy);
1597     nsresult Repaint(PRBool force);
1598     nsresult GetParentWidget(nsIWidget **aParentWidget); 
1599     nsresult SetParentWidget(nsIWidget *aParentWidget);
1600     nsresult GetParentNativeWindow(nativeWindow *aParentNativeWindow);
1601     nsresult SetParentNativeWindow(nativeWindow aParentNativeWindow);
1602     nsresult GetVisibility(PRBool *aVisibility);
1603     nsresult SetVisibility(PRBool aVisibility);
1604     nsresult GetEnabled(PRBool *aEnabled);
1605     nsresult SetEnabled(PRBool aEnabled);
1606     nsresult GetBlurSuppression(PRBool *aBlurSuppression);
1607     nsresult SetBlurSuppression(PRBool aBlurSuppression);
1608     nsresult GetMainWidget(nsIWidget **aMainWidget);
1609     nsresult SetFocus();
1610     nsresult GetTitle(PRUnichar **aTitle);
1611     nsresult SetTitle(const PRUnichar *aTitle);
1612 }
1613
1614 cpp_quote("#define LOAD_FLAGS_NONE 0")
1615
1616 [
1617     object,
1618     uuid(f5d9e7b0-d930-11d3-b057-00a024ffc08c),
1619     local
1620     /* NOT_FROZEN */
1621 ]
1622 interface nsIWebNavigation : nsISupports
1623 {
1624     nsresult GetCanGoBack(PRBool *aCanGoBack);
1625     nsresult GetCanGoForward(PRBool *aCanGoForward);
1626     nsresult GoBack();
1627     nsresult GoForward();
1628     nsresult GotoIndex(PRInt32 index);
1629     nsresult LoadURI(const PRUnichar *aURI, PRUint32 aLoadFlags, nsIURI *aReferrer,
1630             nsIInputStream *aPostData, nsIInputStream *aHeaders);
1631     nsresult Reload(PRUint32 aReloadFlags);
1632     nsresult Stop(PRUint32 aStopFlags);
1633     nsresult GetDocument(nsIDOMDocument **aDocument);
1634     nsresult GetCurrentURI(nsIURI **aCurrentURI);
1635     nsresult GetReferringURI(nsIURI **aReferringURI);
1636     nsresult GetSessionHistory(nsISHistory **aSessionHistory);
1637     nsresult SetSessionHistory(nsISHistory *aSessionHistory);
1638 }
1639
1640 [
1641     object,
1642     uuid(570f39d0-efd0-11d3-b093-00a024ffc08c),
1643     local
1644     /* FROZEN */
1645 ]
1646 interface nsIWebProgress : nsISupports
1647 {
1648     nsresult AddProgressListener(nsIWebProgressListener *aListener, PRUint32 aNotifyMask);
1649     nsresult RemoveProgressListener(nsIWebProgressListener *aListener);
1650     nsresult GetDOMWindow(nsIDOMWindow **aDOMWindow);
1651     nsresult GetIsLoadingDocument(PRBool *aIsLoadingDocument);
1652 }
1653
1654 [
1655     object,
1656     uuid(343700dd-078b-42b6-a809-b9c1d7e951d0),
1657     local
1658     /* NOT_FROZEN */
1659 ]
1660 interface nsIPrintSettings : nsISupports
1661 {
1662     typedef struct { char dummy; } nsIntMargin;
1663
1664     nsresult SetPrintOptions(PRInt32 aType, PRBool aTurnOnOff);
1665     nsresult GetPrintOptions(PRInt32 aType, PRBool *_retval);
1666     nsresult GetPrintOptionsBits(PRInt32 *_retval);
1667     nsresult GetEffectivePageSize(double *aWidth, double *aHeight);
1668     nsresult Clone(nsIPrintSettings **_retval);
1669     nsresult Assign(nsIPrintSettings *aPS);
1670     nsresult GetPrintSession(nsIPrintSession **aPrintSession);
1671     nsresult SetPrintSession(nsIPrintSession *aPrintSession);
1672     nsresult GetStartPageRange(PRInt32 *aStartPageRange);
1673     nsresult SetStartPageRange(PRInt32 aStartPageRange);
1674     nsresult GetEndPageRange(PRInt32 *aEndPageRange);
1675     nsresult SetEndPageRange(PRInt32 aEndPageRange);
1676     nsresult GetEdgeTop(double *aEdgeTop);
1677     nsresult SetEdgeTop(double aEdgeTop);
1678     nsresult GetEdgeLeft(double *aEdgeLeft);
1679     nsresult SetEdgeLeft(double aEdgeLeft);
1680     nsresult GetEdgeBottom(double *aEdgeBottom);
1681     nsresult SetEdgeBottom(double aEdgeBottom);
1682     nsresult GetEdgeRight(double *aEdgeRight);
1683     nsresult SetEdgeRight(double aEdgeRight);
1684     nsresult GetMarginTop(double *aMarginTop);
1685     nsresult SetMarginTop(double aMarginTop);
1686     nsresult GetMarginLeft(double *aMarginLeft);
1687     nsresult SetMarginLeft(double aMarginLeft);
1688     nsresult GetMarginBottom(double *aMarginBottom);
1689     nsresult SetMarginBottom(double aMarginBottom);
1690     nsresult GetMarginRight(double *aMarginRight);
1691     nsresult SetMarginRight(double aMarginRight);
1692     nsresult GetUnwriteableMarginTop(double *aUnwriteableMarginTop);
1693     nsresult SetUnwriteableMarginTop(double aUnwriteableMarginTop);
1694     nsresult GetUnwriteableMarginLeft(double *aUnwriteableMarginLeft);
1695     nsresult SetUnwriteableMarginLeft(double aUnwriteableMarginLeft);
1696     nsresult GetUnwriteableMarginBottom(double *aUnwriteableMarginBottom);
1697     nsresult SetUnwriteableMarginBottom(double aUnwriteableMarginBottom);
1698     nsresult GetUnwriteableMarginRight(double *aUnwriteableMarginRight);
1699     nsresult SetUnwriteableMarginRight(double aUnwriteableMarginRight);
1700     nsresult GetScaling(double *aScaling);
1701     nsresult SetScaling(double aScaling);
1702     nsresult GetPrintBGColors(PRBool *aPrintBGColors);
1703     nsresult SetPrintBGColors(PRBool aPrintBGColors);
1704     nsresult GetPrintBGImages(PRBool *aPrintBGImages);
1705     nsresult SetPrintBGImages(PRBool aPrintBGImages);
1706     nsresult GetPrintRange(PRInt16 *aPrintRange);
1707     nsresult SetPrintRange(PRInt16 aPrintRange);
1708     nsresult GetTitle(PRUnichar **aTitle);
1709     nsresult SetTitle(const PRUnichar *aTitle);
1710     nsresult GetDocURL(PRUnichar **aDocURL);
1711     nsresult SetDocURL(const PRUnichar *aDocURL);
1712     nsresult GetHeaderStrLeft(PRUnichar **aHeaderStrLeft);
1713     nsresult SetHeaderStrLeft(const PRUnichar *aHeaderStrLeft);
1714     nsresult GetHeaderStrCenter(PRUnichar **aHeaderStrCenter);
1715     nsresult SetHeaderStrCenter(const PRUnichar *aHeaderStrCenter);
1716     nsresult GetHeaderStrRight(PRUnichar **aHeaderStrRight);
1717     nsresult SetHeaderStrRight(const PRUnichar *aHeaderStrRight);
1718     nsresult GetFooterStrLeft(PRUnichar **aFooterStrLeft);
1719     nsresult SetFooterStrLeft(const PRUnichar *aFooterStrLeft);
1720     nsresult GetFooterStrCenter(PRUnichar **aFooterStrCenter);
1721     nsresult SetFooterStrCenter(const PRUnichar *aFooterStrCenter);
1722     nsresult GetFooterStrRight(PRUnichar **aFooterStrRight);
1723     nsresult SetFooterStrRight(const PRUnichar *aFooterStrRight);
1724     nsresult GetHowToEnableFrameUI(PRInt16 *aHowToEnableFrameUI);
1725     nsresult SetHowToEnableFrameUI(PRInt16 aHowToEnableFrameUI);
1726     nsresult GetIsCancelled(PRBool *aIsCancelled);
1727     nsresult SetIsCancelled(PRBool aIsCancelled);
1728     nsresult GetPrintFrameTypeUsage(PRInt16 *aPrintFrameTypeUsage);
1729     nsresult SetPrintFrameTypeUsage(PRInt16 aPrintFrameTypeUsage);
1730     nsresult GetPrintFrameType(PRInt16 *aPrintFrameType);
1731     nsresult SetPrintFrameType(PRInt16 aPrintFrameType);
1732     nsresult GetPrintSilent(PRBool *aPrintSilent);
1733     nsresult SetPrintSilent(PRBool aPrintSilent);
1734     nsresult GetShrinkToFit(PRBool *aShrinkToFit);
1735     nsresult SetShrinkToFit(PRBool aShrinkToFit);
1736     nsresult GetShowPrintProgress(PRBool *aShowPrintProgress);
1737     nsresult SetShowPrintProgress(PRBool aShowPrintProgress);
1738     nsresult GetPaperName(PRUnichar **aPaperName);
1739     nsresult SetPaperName(const PRUnichar *aPaperName);
1740     nsresult GetPaperSizeType(PRInt16 *aPaperSizeType);
1741     nsresult SetPaperSizeType(PRInt16 aPaperSizeType);
1742     nsresult GetPaperData(PRInt16 *aPaperData);
1743     nsresult SetPaperData(PRInt16 aPaperData);
1744     nsresult GetPaperWidth(double *aPaperWidth);
1745     nsresult SetPaperWidth(double aPaperWidth);
1746     nsresult GetPaperHeight(double *aPaperHeight);
1747     nsresult SetPaperHeight(double aPaperHeight);
1748     nsresult GetPaperSizeUnit(PRInt16 *aPaperSizeUnit);
1749     nsresult SetPaperSizeUnit(PRInt16 aPaperSizeUnit);
1750     nsresult GetPlexName(PRUnichar **aPlexName);
1751     nsresult SetPlexName(const PRUnichar *aPlexName);
1752     nsresult GetColorspace(PRUnichar **aColorspace);
1753     nsresult SetColorspace(const PRUnichar *aColorspace);
1754     nsresult GetResolutionName(PRUnichar **aResolutionName);
1755     nsresult SetResolutionName(const PRUnichar aResolutionName);
1756     nsresult GetDownloadFonts(PRBool *aDownloadFonts);
1757     nsresult SetDownloadFonts(PRBool aDownloadFonts);
1758     nsresult GetPrintReversed(PRBool *aPrintReversed);
1759     nsresult SetPrintReversed(PRBool aPrintReversed);
1760     nsresult GetPrintInColor(PRBool *aPrintInColor);
1761     nsresult SetPrintInColor(PRBool aPrintInColor);
1762     nsresult GetOrientation(PRInt32 *aOrientation);
1763     nsresult SetOrientation(PRInt32 aOrientation);
1764     nsresult GetPrintCommand(PRUnichar **aPrintCommand);
1765     nsresult SetPrintCommand(const PRUnichar *aPrintCommand);
1766     nsresult GetNumCopies(PRInt32 *aNumCopies);
1767     nsresult SetNumCopies(PRInt32 aNumCopies);
1768     nsresult GetPrinterName(PRUnichar **aPrinterName);
1769     nsresult SetPrinterName(const PRUnichar *aPrinterName);
1770     nsresult GetPrintToFile(PRBool *aPrintToFile);
1771     nsresult SetPrintToFile(PRBool aPrintToFile);
1772     nsresult GetToFileName(PRUnichar **aToFileName);
1773     nsresult SetToFileName(const PRUnichar *aToFileName);
1774     nsresult GetOutputFormat(PRInt16 *aOutputFormat);
1775     nsresult SetOutputFormat(PRInt16 aOutputFormat);
1776     nsresult GetPrintPageDelay(PRInt32 *aPrintPageDelay);
1777     nsresult SetPrintPageDelay(PRInt32 aPrintPageDelay);
1778     nsresult GetIsInitializedFromPrinter(PRBool *aIsInitializedFromPrinter);
1779     nsresult SetIsInitializedFromPrinter(PRBool aIsInitializedFromPrinter);
1780     nsresult GetIsInitializedFromPrefs(PRBool *aIsInitializedFromPrefs);
1781     nsresult SetIsInitializedFromPrefs(PRBool aIsInitializedFromPrefs);
1782     nsresult SetMarginInTwips(nsIntMargin *aMargin);
1783     nsresult SetEdgeInTwips(nsIntMargin *aEdge);
1784     nsresult GetMarginInTwips(nsIntMargin *aMargin);
1785     nsresult GetEdgeInTwips(nsIntMargin *aEdge);
1786     nsresult SetupSilentPrinting();
1787     nsresult SetUnwriteableMarginInTwips(nsIntMargin *aEdge);
1788     nsresult GetUnwriteableMarginInTwips(nsIntMargin *aEdge);
1789 }
1790
1791 [
1792     object,
1793     uuid(9a7ca4b0-fbba-11d4-a869-00105a183419),
1794     local
1795     /* FROZEN */
1796 ]
1797 interface nsIWebBrowserPrint : nsISupports
1798 {
1799     nsresult GetGlobalPrintSettings(nsIPrintSettings **aGlobalPrintSettings);
1800     nsresult GetCurrentPrintSettings(nsIPrintSettings **aCurrentPrintSettings);
1801     nsresult GetCurrentChildDOMWindow(nsIDOMWindow **aCurrentChildDOMWindow);
1802     nsresult GetDoingPrint(PRBool *aDoingPrint);
1803     nsresult GetDoingPrintPreview(PRBool *aDoingPrintPreview);
1804     nsresult GetIsFramesetDocument(PRBool *aIsFramesetDocument);
1805     nsresult GetIsFramesetFrameSelected(PRBool *aIsFramesetFrameSelected);
1806     nsresult GetIsIFrameSelected(PRBool *aIsIFrameSelected);
1807     nsresult GetIsRangeSelection(PRBool *aIsRangeSelection);
1808     nsresult GetPrintPreviewNumPages(PRInt32 *aPrintPreviewNumPages);
1809     nsresult Print(nsIPrintSettings *aThePrintSettings, nsIWebProgressListener *aWPListener);
1810     nsresult PrintPreview(nsIPrintSettings *aThePrintSettings, nsIDOMWindow *aChildDOMWin,
1811                           nsIWebProgressListener *aWPListener);
1812     nsresult PrintPreviewNavigate(PRInt16 aNavType, PRInt32 aPageNum);
1813     nsresult Cancel();
1814     nsresult EnumerateDocumentNames(PRUint32 *aCount, PRUnichar ***aResult);
1815     nsresult ExitPrintPreview();
1816 }
1817
1818 [
1819     object,
1820     uuid(919e792a-6490-40b8-bba5-f9e9ad5640c8),
1821     local
1822     /* NOT_FROZEN */
1823 ]
1824 interface nsIScrollable : nsISupports
1825 {
1826     enum {
1827         ScrollOrientation_X = 1,
1828         ScrollOrientation_Y = 2
1829     };
1830
1831     enum {
1832         Scrollbar_Auto   = 1,
1833         Scrollbar_Never  = 2,
1834         Scrollbar_Always = 3
1835     };
1836
1837     nsresult GetCurScrollPos(PRInt32 scrollOrientation, PRInt32 *curPos);
1838     nsresult SetCurScrollPos(PRInt32 scrollOrientation, PRInt32 curPos);
1839     nsresult SetCurScrollPosEx(PRInt32 curHorizontalPos, PRInt32 curVerticalPos);
1840     nsresult GetScrollRange(PRInt32 scrollOrientation, PRInt32 *minPos, PRInt32 *maxPos);
1841     nsresult SetScrollRange(PRInt32 scrollOrientation, PRInt32 minPos, PRInt32 maxPos);
1842     nsresult SetScrollRangeEx(PRInt32 minHorizontalPos, PRInt32 maxHorizontalPos,
1843             PRInt32 minVerticalPos, PRInt32 maxVerticalPos);
1844     nsresult GetDefaultScrollbarPreferences(PRInt32 scrollOrientation, PRInt32 *scrollbarPref);
1845     nsresult SetDefaultScrollbarPreferences(PRInt32 scrollOrientation, PRInt32 scrollbarPref);
1846     nsresult GetScrollbarVisibility(PRBool *verticalVisible, PRBool *horizontalVisible);
1847 }
1848
1849 [
1850     object,
1851     uuid(c8c0a080-0868-11d3-915f-d9d889d48e3c),
1852     local
1853     /* FROZEN */
1854 ]
1855 interface nsIFile : nsISupports
1856 {
1857     nsresult Append(const nsAString *node);
1858     nsresult AppendNative(const nsAString *node);
1859     nsresult Normalize();
1860     nsresult Create(PRUint32 type, PRUint32 permission);
1861     nsresult GetLeafName(nsAString *aLeafName);
1862     nsresult SetLeafName(const nsAString *aLeafName);
1863     nsresult GetNativeLeafName(nsAString *aLeafName);
1864     nsresult SetNativeLeafName(const nsAString *aLeafName);
1865     nsresult CopyTo(nsIFile *newParentDir, const nsAString *newName);
1866     nsresult CopyToNative(nsIFile *newParentDir, const nsAString *newName);
1867     nsresult CopyToFollowingLinks(nsIFile *newParentDir, const nsAString *newName);
1868     nsresult CopyToFollowingLinksNative(nsIFile *newParentDir, const nsAString *newName);
1869     nsresult MoveTo(nsIFile *newParentDir, const nsAString *newName);
1870     nsresult MoveToNative(nsIFile *newParentDir, const nsAString *newName);
1871     nsresult Remove(PRBool recursive);
1872     nsresult GetPermissions(PRUint32 *aPermissions);
1873     nsresult SetPermissions(PRUint32 pPermissions);
1874     nsresult GetPermissionsOfLink(PRUint32 *aPermissions);
1875     nsresult SetPermissionsOfLink(PRUint32 pPermissions);
1876     nsresult GetLastModifiedTime(PRInt64 *aLastModifiedTime);
1877     nsresult SetLastModifiedTime(PRInt64 aLastModifiedTime);
1878     nsresult GetFileSize(PRInt64 *aFileSize);
1879     nsresult SetFileSize(PRInt64 aFileSize);
1880     nsresult GetFileSizeOfLink(PRInt64 *aFileSizeOfLink);
1881     nsresult GetTarget(nsAString *aTarget);
1882     nsresult GetNativeTarget(nsACString *aNativeTarget);
1883     nsresult GetPath(nsAString *aPath);
1884     nsresult GetNativePath(nsACString *aNativePath);
1885     nsresult Exists(PRBool *_retval);
1886     nsresult IsWritable(PRBool *_retval);
1887     nsresult IsReadable(PRBool *_retval);
1888     nsresult IsExecutable(PRBool *_retval);
1889     nsresult IsHidden(PRBool *_retval);
1890     nsresult IsDirectory(PRBool *_retval);
1891     nsresult IsFile(PRBool *_retval);
1892     nsresult IsSymlink(PRBool *_retval);
1893     nsresult IsSpecial(PRBool *_retval);
1894     nsresult CreateUnique(PRUint32 type, PRUint32 permission);
1895     nsresult Clone(nsIFile **_retval);
1896     nsresult Equals(nsIFile *inFile, PRBool *_retval);
1897     nsresult Contains(nsIFile *inFile, PRBool recir, PRBool *_retval);
1898     nsresult GetParent(nsIFile **aParent);
1899     nsresult GetDirectoryEntries(nsISimpleEnumerator **aDirectoryEntries);
1900 }
1901
1902 [
1903     object,
1904     uuid(56c35506-f14b-11d3-99d3-ddbfac2ccf65),
1905     local
1906     /* FROZEN */
1907 ]
1908 interface nsIPrefBranch : nsISupports
1909 {
1910     nsresult GetRoot(char **aRoot);
1911     nsresult GetPrefType(const char *aPrefName, PRInt32 *_retval);
1912     nsresult GetBoolPref(const char *aPrefName, PRBool *_retval);
1913     nsresult SetBoolPref(const char *aPrefName, PRInt32 aValue);
1914     nsresult GetCharPref(const char *aPrefName, char **_retval);
1915     nsresult SetCharPref(const char *aPrefName, const char *aValue);
1916     nsresult GetIntPref(const char *aPrefName, PRInt32 *_retval);
1917     nsresult SetIntPref(const char *aPrefName, PRInt32 aValue);
1918     nsresult GetComplexValue(const char *aPrefName, const nsIID *aType, void **aValue);
1919     nsresult SetComplexValue(const char *aPrefName, const nsIID *aType, nsISupports *aValue);
1920     nsresult ClearUserPref(const char *aPrefName);
1921     nsresult LockPref(const char *aPrefName);
1922     nsresult PrefHasUserValue(const char *aPrefName, PRBool *_retval);
1923     nsresult PrefIsLocked(const char *aPrefName, PRBool *_retval);
1924     nsresult UnlockPref(const char *aPrefName);
1925     nsresult DeleteBranch(const char *aStartingAt);
1926     nsresult GetChildList(const char *aStartingAt, PRUint32 *aCount, char ***aChildArray);
1927     nsresult ResetBranch(const char *aStartingAt);
1928 }
1929
1930 [
1931     object,
1932     uuid(15fd6940-8ea7-11d3-93ad-00104ba0fd40),
1933     local
1934     /* FROZEN */
1935 ]
1936 interface nsIProtocolHandler : nsISupports
1937 {
1938     nsresult GetScheme(nsACString *aScheme);
1939     nsresult GetDefaultPort(PRInt32 *aDefaultPort);
1940     nsresult GetProtocolFlags(PRUint32 *aProtocolFlags);
1941     nsresult NewURI(const nsACString *aSpec, const char *aOriginCharset,
1942                     nsIURI *aBaseURI, nsIURI **_retval);
1943     nsresult NewChannel(nsIURI *aURI, nsIChannel **_retval);
1944     nsresult AllowPort(PRInt32 port, const char *scheme, PRBool *_retval);
1945 }
1946
1947 [
1948     object,
1949     uuid(0e61f3b2-34d7-4c79-bfdc-4860bc7341b7),
1950     local
1951     /* NOT_FROZEN */
1952 ]
1953 interface nsIExternalProtocolHandler : nsIProtocolHandler
1954 {
1955     nsresult ExternalAppExistsForScheme(const nsACString *scheme, PRBool *_retval);
1956 }
1957
1958 [
1959     object,
1960     uuid(bddeda3f-9020-4d12-8c70-984ee9f7935e),
1961     local
1962     /* FROZEN */
1963 ]
1964 interface nsIIOService : nsISupports
1965 {
1966     nsresult GetProtocolHandler(const char *aScheme, nsIProtocolHandler **_retval);
1967     nsresult GetProtocolFlags(const char *aScheme, PRUint32 *_retval);
1968     nsresult NewURI(const nsACString *aSpec, const char *aOriginCharset, nsIURI *aBaseURI,
1969                     nsIURI **_retval);
1970     nsresult NewFileURI(nsIFile *aFile, nsIURI **_retval);
1971     nsresult NewChannelFromURI(nsIURI *aURI, nsIChannel **_retval);
1972     nsresult NewChannel(const nsACString *aSpec, const char *aOriginCharset, nsIURI *aBaseURI,
1973                         nsIChannel **_retval);
1974     nsresult GetOffline(PRBool *aOffline);
1975     nsresult SetOffline(PRBool aOffline);
1976     nsresult AllowPort(PRInt32 aPort, const char *aScheme, PRBool *_retval);
1977     nsresult ExtractScheme(const nsACString *urlString, nsACString * _retval);
1978 }
1979
1980 [
1981     object,
1982     uuid(a50d5516-5c0a-4f08-b427-703ca0c44ac3),
1983     local,
1984     /* NOT_FROZEN */
1985 ]
1986 interface nsINetUtil : nsISupports
1987 {
1988     nsresult ParseContentType(const nsACString *aTypeHeader, nsACString *aCharset,
1989             PRBool *aHadCharset, nsACString *_retval);
1990     nsresult ProtocolHasFlags(nsIURI *aURI, PRUint32 aFlag, PRBool *_retval);
1991     nsresult URIChainHasFlags(nsIURI *aURI, PRUint32 aFlags, PRBool *_retval);
1992     nsresult ToImmutableURI(nsIURI *aURI, nsIURI **_retval);
1993     nsresult EscapeString(const nsACString *aString, PRUint32 aEscapeType, nsACString *_retval);
1994     nsresult EscapeURL(const nsACString *aStr, PRUint32 aFlags, nsACString *_retval);
1995     nsresult UnescapeString(const nsACString *aStr, PRUint32 aFlags, nsACString *_retval);
1996     nsresult ExtractCharsetFromContentType(const nsACString *aTypeHeader, nsACString *aCharset,
1997             PRInt32 *aCharsetStart, PRInt32 *aCharsetEnd, PRBool *_retval);
1998 }
1999
2000 [
2001     object,
2002     uuid(9c5d3c58-1dd1-11b2-a1c9-f3699284657a),
2003     local
2004     /* FROZEN */
2005 ]
2006 interface nsIWebBrowserFocus : nsISupports
2007 {
2008     nsresult Activate();
2009     nsresult Deactivate();
2010     nsresult SetFocusAtFirstElement();
2011     nsresult SetFocusAtLastElement();
2012     nsresult GetFocusedWindow(nsIDOMWindow **aFocusedWindow);
2013     nsresult SetFocusedWindow(nsIDOMWindow *aFocusedWindow);
2014     nsresult GetFocusedElement(nsIDOMElement **aFocusedElement);
2015     nsresult SetFocusedElement(nsIDOMElement *aFocusedElement);
2016 }
2017
2018 [
2019     object,
2020     uuid(ba434c60-9d52-11d3-afb0-00a024ffc08c),
2021     local
2022     /* FROZEN */
2023 ]
2024 interface nsIWebBrowserChrome : nsISupports
2025 {
2026     nsresult SetStatus(PRUint32 statusType, const PRUnichar *status);
2027     nsresult GetWebBrowser(nsIWebBrowser **aWebBrowser);
2028     nsresult SetWebBrowser(nsIWebBrowser *aWebBrowser);
2029     nsresult GetChromeFlags(PRUint32 *aChromeFlags);
2030     nsresult SetChromeFlags(PRUint32 aChromeFlags);
2031     nsresult DestroyBrowserWindow();
2032     nsresult SizeBrowserTo(PRInt32 aCX, PRInt32 aCY);
2033     nsresult ShowAsModal();
2034     nsresult IsWindowModal(PRBool *_retval);
2035     nsresult ExitModalEventLoop(nsresult aStatus);
2036 }
2037
2038 [
2039     object,
2040     uuid(df31c120-ded6-11d1-bd85-00805f8ae3f4),
2041     local
2042     /* FROZEN */
2043 ]
2044 interface nsIDOMEventListener : nsISupports
2045 {
2046     nsresult HandleEvent(nsIDOMEvent *event);
2047 }
2048
2049 [
2050     object,
2051     uuid(1c773b30-d1cf-11d2-bd95-00805f8ae3f4),
2052     local
2053     /* FROZEN */
2054 ]
2055 interface nsIDOMEventTarget : nsISupports
2056 {
2057     nsresult AddEventListener(const nsAString *type, nsIDOMEventListener *listener, PRBool useCapture);
2058     nsresult RemoveEventListener(const nsAString *type, nsIDOMEventListener *listener, PRBool useCapture);
2059     nsresult DispatchEvent(nsIDOMEvent *evt, PRBool *_retval);
2060 }
2061
2062 [
2063     object,
2064     uuid(a66b7b80-ff46-bd97-0080-5f8ae38add32),
2065     local
2066     /* FROZEN */
2067 ]
2068 interface nsIDOMEvent : nsISupports
2069 {
2070     nsresult GetType(nsAString *aType);
2071     nsresult GetTarget(nsIDOMEventTarget **aTarget);
2072     nsresult GetCurrentTarget(nsIDOMEventTarget **aCurrentTarget);
2073     nsresult GetEventPhase(PRUint16 *aEventPhase);
2074     nsresult GetBubbles(PRBool *aBubbles);
2075     nsresult GetCancelable(PRBool *aCancelable);
2076     nsresult GetTimeStamp(DOMTimeStamp *aTimeStamp);
2077     nsresult StopPropagation();
2078     nsresult PreventDefault();
2079     nsresult InitEvent(const nsAString *eventTypeArg, PRBool canBubbleArg, PRBool cancelableArg);
2080 }
2081
2082 cpp_quote("#define CONTEXT_NONE              0x00")
2083 cpp_quote("#define CONTEXT_LINK              0x01")
2084 cpp_quote("#define CONTEXT_IMAGE             0x02")
2085 cpp_quote("#define CONTEXT_DOCUMENT          0x04")
2086 cpp_quote("#define CONTEXT_TEXT              0x08")
2087 cpp_quote("#define CONTEXT_INPUT             0x10")
2088 cpp_quote("#define CONTEXT_BACKGROUND_IMAGE  0x20")
2089
2090 [
2091     object,
2092     uuid(3478b6b0-3875-11d4-94ef-0020183bf181),
2093     local
2094     /* FROZEN */
2095 ]
2096 interface nsIContextMenuListener : nsISupports
2097 {
2098     nsresult OnShowContextMenu(PRUint32 aContextFlags, nsIDOMEvent *aEvent, nsIDOMNode *aNode);
2099 }
2100
2101 [
2102     object,
2103     uuid(a6cf90c3-15b3-11d2-932e-00805f8add32),
2104     local
2105     /* FROZEN */
2106 ]
2107 interface nsIDOMUIEvent : nsIDOMEvent
2108 {
2109     nsresult GetView(nsIDOMAbstractView **aView);
2110     nsresult GetDetail(PRInt32 *aDetail);
2111     nsresult InitUIEvent(const nsAString *typeArg, PRBool canBubbleArg, PRBool cancelableArg,
2112             nsIDOMAbstractView *viewArg, PRInt32 detailArg);
2113 }
2114
2115 [
2116     object,
2117     uuid(ff751edc-8b02-aae7-0010-8301838a3123),
2118     local
2119     /* FROZEN */
2120 ]
2121 interface nsIDOMMouseEvent : nsIDOMUIEvent
2122 {
2123     nsresult GetScreenX(PRInt32 *aScreenX);
2124     nsresult GetScreenY(PRInt32 *aScreenY);
2125     nsresult GetClientX(PRInt32 *aClientX);
2126     nsresult GetClientY(PRInt32 *aClientY);
2127     nsresult GetCtrlKey(PRBool *aCtrlKey);
2128     nsresult GetShiftKey(PRBool *aShiftKey);
2129     nsresult GetAltKey(PRBool *aAltKey);
2130     nsresult GetMetaKey(PRBool *aMetaKey);
2131     nsresult GetButton(PRUint16 *aButton);
2132     nsresult GetRelatedTarget(nsIDOMEventTarget * *aRelatedTarget);
2133     nsresult InitMouseEvent(const nsAString *typeArg, PRBool canBubbleArg, PRBool cancelableArg,
2134             nsIDOMAbstractView *viewArg, PRInt32 detailArg, PRInt32 screenXArg, PRInt32 screenYArg,
2135             PRInt32 clientXArg, PRInt32 clientYArg, PRBool ctrlKeyArg, PRBool altKeyArg,
2136             PRBool shiftKeyArg, PRBool metaKeyArg, PRUint16 buttonArg,
2137             nsIDOMEventTarget *relatedTargetArg);
2138 }
2139
2140 [
2141     object,
2142     uuid(028e0e6e-8b01-11d3-aae7-0010838a3123),
2143     local
2144     /* NOT_FROZEN */
2145 ]
2146 interface nsIDOMKeyEvent : nsIDOMUIEvent
2147 {
2148     nsresult GetCharCode(PRUint32 *aCharCode);
2149     nsresult GetKeyCode(PRUint32 *aKeyCode);
2150     nsresult GetAltKey(PRBool *aAltKey);
2151     nsresult GetCtrlKey(PRBool *aCtrlKey);
2152     nsresult GetShiftKey(PRBool *aShiftKey);
2153     nsresult GetMetaKey(PRBool *aMetaKey);
2154     nsresult InitKeyEvent(const nsAString *typeArg, PRBool canBubbleArg,
2155             PRBool cancelableArg, nsIDOMAbstractView *viewArg, PRBool ctrlKeyArg,
2156             PRBool altKeyArg, PRBool shiftKeyArg, PRBool metaKeyArg, PRUint32 keyCodeArg,
2157             PRUint32 charCodeArg);
2158 }
2159
2160 [
2161     object,
2162     uuid(3e5432cd-9568-4bd1-8cbe-d50aba110743),
2163     local
2164     /* FROZEN */
2165 ]
2166 interface nsIEmbeddingSiteWindow : nsISupports
2167 {
2168     nsresult SetDimensions(PRUint32 flags, PRInt32 x, PRInt32 y, PRInt32 cx, PRInt32 cy);
2169     nsresult GetDimensions(PRUint32 flags, PRInt32 *x, PRInt32 *y, PRInt32 *cx, PRInt32 *cy);
2170     nsresult SetFocus();
2171     nsresult GetVisibility(PRBool *aVisibility);
2172     nsresult SetVisibility(PRBool aVisibility);
2173     nsresult GetTitle(PRUnichar **aTitle);
2174     nsresult SetTitle(const PRUnichar *aTitle);
2175     nsresult GetSiteWindow(void **aSiteWindow);
2176 }
2177
2178 [
2179     object,
2180     uuid(2417cbfe-65ad-48a6-b4b6-eb84db174392),
2181     local
2182     /* FROZEN */
2183 ]
2184 interface nsIComponentRegistrar : nsISupports
2185 {
2186     nsresult AutoRegister(nsIFile *aSpec);
2187     nsresult AutoUnregister(nsIFile *aSpec);
2188     nsresult RegisterFactory(const nsCID *aClass, const char *aClassName,
2189             const char *aContractID, nsIFactory *aFactory);
2190     nsresult UnregisterFactory(const nsCID *aClass, nsIFactory *aFactory);
2191     nsresult RegisterFactoryLocation(const nsCID *aClass, const char *aClassName,
2192             const char *aContractID, nsIFile *aFile, const char *aLoaderStr,
2193             const char *aType);
2194     nsresult UnregisterFactoryLocation(const nsCID *aClass, nsIFile *aFile);
2195     nsresult IsCIDRegistered(const nsCID *aClass, PRBool *_retval);
2196     nsresult IsContractIDRegistered(const char *aContractID, PRBool *_retval);
2197     nsresult EnumerateCIDs(nsISimpleEnumerator **_retval);
2198     nsresult EnumerateContractIDs(nsISimpleEnumerator **_retval);
2199     nsresult CIDToContractID(const nsCID *aClass, char **_retval);
2200     nsresult ContractIDToCID(const char *aContractID, nsCID **_retval);
2201 }
2202
2203 [
2204     object,
2205     uuid(1630c61a-325e-49ca-8759-a31b16c47aa5),
2206     local
2207     /* FROZEN */
2208 ]
2209 interface nsIPromptService : nsISupports
2210 {
2211     nsresult Alert(nsIDOMWindow *aParent, const PRUnichar *aDialogTitle,
2212             const PRUnichar *aText);
2213     nsresult AlertCheck(nsIDOMWindow *aParent, const PRUnichar *aDialogTitle,
2214             const PRUnichar *aText, const PRUnichar *aCheckMsg, PRBool *aCheckState);
2215     nsresult Confirm(nsIDOMWindow *aParent, const PRUnichar *aDialogTitle,
2216             const PRUnichar *aText, PRBool *_retval);
2217     nsresult ConfirmCheck(nsIDOMWindow *aParent, const PRUnichar *aDialogTitle,
2218             const PRUnichar *aText, const PRUnichar *aCheckMsg, PRBool *aCheckState,
2219             PRBool *_retval);
2220     nsresult ConfirmEx(nsIDOMWindow *aParent, const PRUnichar *aDialogTitle,
2221             const PRUnichar *aText, PRUint32 aButtonFlags, const PRUnichar *aButton0Title,
2222             const PRUnichar *aButton1Title, const PRUnichar *aButton2Title,
2223             const PRUnichar *aCheckMsg, PRBool *aCheckState, PRInt32 *_retval);
2224     nsresult Prompt(nsIDOMWindow *aParent, const PRUnichar *aDialogTitle,
2225             const PRUnichar *aText, PRUnichar **aValue, const PRUnichar *aCheckMsg,
2226             PRBool *aCheckState, PRBool *_retval);
2227     nsresult PromptUsernameAndPassword(nsIDOMWindow *aParent, const PRUnichar *aDialogTitle,
2228             const PRUnichar *aText, PRUnichar **aUsername, PRUnichar **aPassword,
2229             const PRUnichar *aCheckMsg, PRBool *aCheckState, PRBool *_retval);
2230     nsresult PromptPassword(nsIDOMWindow *aParent, const PRUnichar *aDialogTitle,
2231             const PRUnichar *aText, PRUnichar **aPassword, const PRUnichar *aCheckMsg,
2232             PRBool *aCheckState, PRBool *_retval);
2233     nsresult Select(nsIDOMWindow *aParent, const PRUnichar *aDialogTitle,
2234             const PRUnichar *aText, PRUint32 aCount, const PRUnichar **aSelectList,
2235             PRInt32 *aOutSelection, PRBool *_retval);
2236 }
2237
2238 [
2239     object,
2240     uuid(b128a1e6-44f3-4331-8fbe-5af360ff21ee),
2241     local
2242     /* FROZEN */
2243 ]
2244 interface nsITooltipTextProvider : nsISupports
2245 {
2246     nsresult GetNodeText(nsIDOMNode *aNode, PRUnichar **aText, PRBool *_retval);
2247 }
2248
2249 [
2250     object,
2251     uuid(02b0625a-e7f3-11d2-9f5a-006008a6efe9),
2252     local
2253     /* FROZEN */
2254 ]
2255 interface nsIProfile : nsISupports
2256 {
2257     nsresult GetProfileCount(PRInt32 *aProfileCount);
2258     nsresult GetProfileList(PRUint32 *length, PRUnichar ***profileNames);
2259     nsresult ProfileExists(const PRUnichar *profileName, PRBool *_retval);
2260     nsresult GetCurrentProfile(PRUnichar * *aCurrentProfile);
2261     nsresult SetCurrentProfile(const PRUnichar * aCurrentProfile);
2262     nsresult ShutDownCurrentProfile(PRUint32 shutDownType);
2263     nsresult CreateNewProfile(const PRUnichar *profileName,
2264             const PRUnichar *nativeProfileDir, const PRUnichar *langcode,
2265             PRBool useExistingDir);
2266     nsresult RenameProfile(const PRUnichar *oldName, const PRUnichar *newName);
2267     nsresult DeleteProfile(const PRUnichar *name, PRBool canDeleteFiles);
2268     nsresult CloneProfile(const PRUnichar *profileName);
2269 }
2270
2271 [
2272     object,
2273     uuid(30465632-a777-44cc-90f9-8145475ef999),
2274     local
2275     /* FROZEN */
2276 ]
2277 interface nsIWindowCreator : nsISupports
2278 {
2279     nsresult CreateChromeWindow(nsIWebBrowserChrome *parent, PRUint32 chromeFlags,
2280                                    nsIWebBrowserChrome **_retval);
2281 }
2282
2283 [
2284     object,
2285     uuid(f673ec81-a4b0-11d6-964b-eb5a2bf216fc),
2286     local
2287     /* NOT_FROZEN */
2288 ]
2289 interface nsIWindowCreator2 : nsIWindowCreator
2290 {
2291     nsresult CreateChromeWindow2(nsIWebBrowserChrome *parent, PRUint32 chromeFlags,
2292                                  PRUint32 contextFlags, nsIURI *uri, PRBool *cancel,
2293                                  nsIWebBrowserChrome **_retval);
2294 }
2295
2296 [
2297     object,
2298     uuid(002286a8-494b-43b3-8ddd-49e3fc50622b),
2299     local
2300     /* FROZEN */
2301 ]
2302 interface nsIWindowWatcher : nsISupports
2303 {
2304     nsresult OpenWindow(nsIDOMWindow *aParent, const char *aUrl, const char *aName,
2305                         const char *aFeatures, nsISupports *aArguments, nsIDOMWindow **_retval);
2306     nsresult RegisterNotification(nsIObserver *aObserver);
2307     nsresult UnregisterNotification(nsIObserver *aObserver);
2308     nsresult GetWindowEnumerator(nsISimpleEnumerator **_retval);
2309     nsresult GetNewPrompter(nsIDOMWindow *aParent, nsIPrompt **_retval);
2310     nsresult GetNewAuthPrompter(nsIDOMWindow *aParent, nsIAuthPrompt **_retval);
2311     nsresult SetWindowCreator(nsIWindowCreator *creator);
2312     nsresult GetChromeForWindow(nsIDOMWindow *aWindow, nsIWebBrowserChrome **_retval);
2313     nsresult GetWindowByName(const PRUnichar *aTargetName, nsIDOMWindow *aCurrentWindow,
2314                              nsIDOMWindow **_retval);
2315     nsresult GetActiveWindow(nsIDOMWindow **aActiveWindow);
2316     nsresult SetActiveWindow(nsIDOMWindow *aActiveWindow);
2317 }
2318
2319 [
2320     object,
2321     uuid(274cd32e-3675-47e1-9d8a-fc6504ded9ce),
2322     local
2323     /* NOT_FROZEN */
2324 ]
2325 interface nsIEditingSession : nsISupports
2326 {
2327     nsresult GetEditorStatus(PRUint32 *aEditorStatus);
2328     nsresult MakeWindowEditable(nsIDOMWindow *window, const char *aEditorType,
2329             PRBool doAfterUriLoad, PRBool aMakeWholeDocumentEditable, PRBool aInteractive);
2330     nsresult WindowIsEditable(nsIDOMWindow *window, PRBool *_retval);
2331     nsresult GetEditorForWindow(nsIDOMWindow *window, nsIEditor **_retval);
2332     nsresult SetupEditorOnWindow(nsIDOMWindow *window);
2333     nsresult TearDownEditorOnWindow(nsIDOMWindow *window);
2334     nsresult SetEditorOnControllers(nsIDOMWindow *aWindow, nsIEditor *aEditor);
2335     nsresult DisableJSAndPlugins(nsIDOMWindow *aWindow);
2336     nsresult RestoreJSAndPlugins(nsIDOMWindow *aWindow);
2337     nsresult DetachFromWindow(nsIDOMWindow *aWindow);
2338     nsresult ReattachToWindow(nsIDOMWindow *aWindow);
2339 }
2340
2341 [
2342     object,
2343     uuid(83f892cf-7ed3-490e-967a-62640f3158e1),
2344     local
2345     /* NOT_FROZEN */
2346 ]
2347 interface nsICommandParams : nsISupports
2348 {
2349     nsresult GetValueType(const char *name, PRInt16 *_retval);
2350     nsresult GetBooleanValue(const char *name, PRBool *_retval);
2351     nsresult GetLongValue(const char *name, PRInt32 *_retval);
2352     nsresult GetDoubleValue(const char *name, double *_retval);
2353     nsresult GetStringValue(const char *name, nsAString *_retval);
2354     nsresult GetCStringValue(const char *name, char **_retval);
2355     nsresult GetISupportsValue(const char *name, nsISupports **_retval);
2356     nsresult SetBooleanValue(const char *name, PRBool value);
2357     nsresult SetLongValue(const char *name, PRInt32 value);
2358     nsresult SetDoubleValue(const char *name, double value);
2359     nsresult SetStringValue(const char *name, const nsAString *value);
2360     nsresult SetCStringValue(const char *name, const char *value);
2361     nsresult SetISupportsValue(const char *name, nsISupports *value);
2362     nsresult RemoveValue(const char *name);
2363     nsresult HasMoreElements(PRBool *_retval);
2364     nsresult First();
2365     nsresult GetNext(char **_retval);
2366 }
2367
2368 [
2369     object,
2370     uuid(080d2001-f91e-11d4-a73c-f9242928207c),
2371     local
2372     /* NOT_FROZEN */
2373 ]
2374 interface nsICommandManager : nsISupports
2375 {
2376     nsresult AddCommandObserver(nsIObserver *aCommandObserver, const char *aCommandToObserve);
2377     nsresult RemoveCommandObserver(nsIObserver *aCommandObserver, const char *aCommandObserved);
2378     nsresult IsCommandSupported(const char *aCommandName, nsIDOMWindow *aTargetWindow, PRBool *_retval);
2379     nsresult IsCommandEnabled(const char *aCommandName, nsIDOMWindow *aTargetWindow, PRBool *_retval);
2380     nsresult GetCommandState(const char *aCommandName, nsIDOMWindow *aTargetWindow,
2381             nsICommandParams *aCommandParams);
2382     nsresult DoCommand(const char *aCommandName, nsICommandParams *aCommandParams,
2383             nsIDOMWindow *aTargetWindow);
2384 }
2385
2386 [
2387     object,
2388     uuid(47b82b60-a36f-4167-8072-6f421151ed50),
2389     local
2390     /* NOT_FROZEN */
2391 ]
2392 interface nsIControllerContext : nsISupports
2393 {
2394     nsresult Init(nsIControllerCommandTable *aCommandTable);
2395     nsresult SetCommandContext(nsISupports *aCommandContext);
2396 }
2397
2398 [
2399     object,
2400     uuid(d5b61b82-1da4-11d3-bf87-00105a1b0627),
2401     local
2402     /* NOT_FROZEN */
2403 ]
2404 interface nsIController : nsISupports
2405 {
2406     nsresult IsCommandEnabled(const char *command, PRBool *_retval);
2407     nsresult SupportsCommand(const char *command, PRBool *_retval);
2408     nsresult DoCommand(const char *command);
2409     nsresult OnEvent(const char *eventName);
2410 }
2411
2412 [
2413     object,
2414     uuid(34769de0-30d0-4cef-894a-fcd8bb27c4b4),
2415     local
2416     /* NOT_FROZEN */
2417 ]
2418 interface nsIContentSerializer : nsISupports
2419 {
2420     nsresult Init(PRUint32 flags, PRUint32 aWrapColumn, const char* aCharSet, PRBool aIsCopying,
2421             PRBool aIsWholeDocument);
2422     nsresult AppendText(nsIDOMText *aText, PRInt32 aStartOffset, PRInt32 aEndOffset, nsAString *aStr);
2423     nsresult AppendCDATASection(nsIDOMCDATASection *aCDATASection, PRInt32 aStartOffset,
2424             PRInt32 aEndOffset, nsAString *aStr);
2425     nsresult AppendProcessingInstruction(nsIDOMProcessingInstruction* aPI, PRInt32 aStartOffset,
2426             PRInt32 aEndOffset, nsAString *aStr);
2427     nsresult AppendComment(nsIDOMComment *aComment, PRInt32 aStartOffset, PRInt32 aEndOffset,
2428             nsAString *aStr);
2429     nsresult AppendDoctype(nsIDOMDocumentType *aDoctype, nsAString *aStr);
2430     nsresult AppendElementStart(nsIDOMElement *aElement, nsIDOMElement *aOriginalElement,
2431             nsAString *aStr);
2432     nsresult AppendElementEnd(nsIDOMElement *aElement, nsAString *aStr);
2433     nsresult Flush(nsAString *aStr);
2434     nsresult AppendDocumentStart(nsIDOMDocument *aDocument, nsAString *aStr);
2435 }
2436
2437 [
2438     object,
2439     uuid(96b60ba0-634a-41e4-928e-78ab0b3c4b46),
2440     local
2441     /* NOT_FROZEN */
2442 ]
2443 interface nsIEditor  : nsISupports
2444 {
2445     typedef void *nsIPresShellPtr;
2446     typedef void *nsIContentPtr;
2447
2448     nsresult GetSelection([out] nsISelection *_retval);
2449     nsresult Init([in] nsIDOMDocument *doc, [in] nsIPresShellPtr shell, [in] nsIContentPtr aRoot, [in] nsISelectionController *aSelCon, [in] PRUint32 aFlags);
2450     nsresult SetAttributeOrEquivalent([in] nsIDOMElement *element, [in] const nsAString *sourceAttrName, [in] const nsAString *sourceAttrValue, [in] PRBool aSuppressTransaction);
2451     nsresult RemoveAttributeOrEquivalent([in] nsIDOMElement *element, [in] const nsAString *sourceAttrName, [in] PRBool aSuppressTransaction);
2452     nsresult PostCreate();
2453     nsresult PreDestroy();
2454     nsresult GetFlags([out] PRUint32 *_retval);
2455     nsresult SetFlags([in] PRUint32 val);
2456     nsresult GetContentsMIMEType([out] char **_retval);
2457     nsresult SetContentsMIMEType([in] const char *val);
2458     nsresult GetIsDocumentEditable([out] PRBool *_retval);
2459     nsresult GetDocument([out] nsIDOMDocument **_retval);
2460     nsresult GetRootElement([out] nsIDOMElement **_retval);
2461     nsresult GetSelectionController([out] nsISelectionController **_retval);
2462     nsresult DeleteSelection([in] PRInt16 action);
2463     nsresult GetDocumentIsEmpty([out] PRBool *_retval);
2464     nsresult GetDocumentModified([out] PRBool *_retval);
2465     nsresult GetDocumentCharacterSet([out] nsACString *_retval);
2466     nsresult SetDocumentCharacterSet([in] const nsACString *val);
2467     nsresult ResetModificationCount();
2468     nsresult GetModificationCount([out] PRInt32 *_retval);
2469     nsresult IncrementModificationCount([in] PRInt32 aModCount);
2470     nsresult GetTransactionManager([out] nsITransactionManager **_retval);
2471     nsresult SetTransactionManager(nsITransactionManager *aTransactionManager);
2472     nsresult DoTransaction([in] nsITransaction *txn);
2473     nsresult EnableUndo([in] PRBool enable);
2474     nsresult Undo([in] PRUint32 count);
2475     nsresult CanUndo([out] PRBool *isEnabled, [out] PRBool *canUndo);
2476     nsresult Redo([in] PRUint32 count);
2477     nsresult CanRedo([out] PRBool *isEnabled, [out] PRBool *canRedo);
2478     nsresult BeginTransaction();
2479     nsresult EndTransaction();
2480     nsresult BeginPlaceHolderTransaction([in] nsIAtom *name);
2481     nsresult EndPlaceHolderTransaction();
2482     nsresult ShouldTxnSetSelection([out] PRBool *_retval);
2483     nsresult SetShouldTxnSetSelection([in] PRBool should);
2484     nsresult GetInlineSpellChecker([out] nsIInlineSpellChecker **_retval);
2485     nsresult SyncRealTimeSpell();
2486     nsresult SetSpellcheckUserOverride(PRBool enable);
2487     nsresult Cut();
2488     nsresult CanCut([out] PRBool *_retval);
2489     nsresult Copy();
2490     nsresult CanCopy([out] PRBool *_retval);
2491     nsresult Paste([in] PRInt32 aSelectionType);
2492     nsresult CanPaste([in] PRInt32 aSelectionType, [out] PRBool *_retval);
2493     nsresult SelectAll();
2494     nsresult BeginningOfDocument();
2495     nsresult EndOfDocument();
2496     nsresult CanDrag([in] nsIDOMEvent *aEvent, [out] PRBool *_retval);
2497     nsresult DoDrag([in] nsIDOMEvent *aEvent);
2498     nsresult InsertFromDrop([in] nsIDOMEvent *aEvent);
2499     nsresult SetAttribute([in] nsIDOMElement *aElement, [in] const nsAString *attributestr, [in] const nsAString *attvalue);
2500     nsresult GetAttributeValue([in] nsIDOMElement *aElement, [in] const nsAString *attributestr, [out] nsAString *resultValue, PRBool *_retval);
2501     nsresult RemoveAttribute([in] nsIDOMElement *aElement, [in] const nsAString *aAttribute);
2502     nsresult CloneAttribute([in] const nsAString *aAttribute, [in] nsIDOMNode *aDestNode, [in] nsIDOMNode *aSourceNode);
2503     nsresult CloneAttributes([in] nsIDOMNode *destNode, [in] nsIDOMNode *sourceNode);
2504     nsresult CreateNode([in] const nsAString *tag, [in] nsIDOMNode *parent, [in] PRInt32 position, [out] nsIDOMNode **_retval);
2505     nsresult InsertNode([in] nsIDOMNode *node, [in] nsIDOMNode *parent, [in] PRInt32 aPosition);
2506     nsresult SplitNode([in] nsIDOMNode *existingRightNode, [in] PRInt32 offset, [out] nsIDOMNode **newLeftNode);
2507     nsresult JoinNodes([in] nsIDOMNode *leftNode, [in] nsIDOMNode *rightNode, [in] nsIDOMNode *parent);
2508     nsresult DeleteNode([in] nsIDOMNode *child);
2509     nsresult MarkNodeDirty([in] nsIDOMNode *node);
2510     nsresult SwitchTextDirection();
2511     nsresult OutputToString([in] nsAString formatType, [in] PRUint32 flags, [out] nsAString *_retval);
2512     nsresult OutputToStream([in] nsIOutputStream *aStream, [in] nsAString *formatType, [in] nsACString *charsetOverride, [in] PRUint32 flags);
2513     nsresult AddEditorObserver([in] nsIEditorObserver *observer);
2514     nsresult RemoveEditorObserver([in] nsIEditorObserver *observer);
2515     nsresult AddEditActionListener([in] nsIEditActionListener *listener);
2516     nsresult RemoveEditActionListener([in] nsIEditActionListener *listener);
2517     nsresult AddDocumentStateListener([in] nsIDocumentStateListener *listener);
2518     nsresult RemoveDocumentStateListener([in] nsIDocumentStateListener *listener);
2519     nsresult DumpContentTree();
2520     nsresult DebugDumpContent();
2521     nsresult DebugUnitTests([out] PRInt32 *outNumTests, [out] PRInt32 *outNumTestsFailed);
2522     PRBool IsModifiableNode(nsIDOMNode *aNode);
2523 }
2524
2525 [
2526     object,
2527     uuid(afc36593-5787-4420-93d9-b2c0ccbf0cad),
2528     local
2529     /* NOT_FROZEN */
2530 ]
2531 interface nsIHTMLEditor : nsISupports
2532 {
2533     nsresult AddDefaultProperty([in] nsIAtom *aProperty, [in] nsAString *aAttribute, [in] nsAString *aValue);
2534     nsresult RemoveDefaultProperty([in] nsIAtom *aProperty, [in] nsAString *aAttribute, [in] nsAString *aValue);
2535     nsresult RemoveAllDefaultProperties();
2536     nsresult SetCSSInlineProperty([in] nsIAtom *aProperty, [in] nsAString *aAttribute, [in] nsAString *aValue);
2537     nsresult SetInlineProperty([in] nsIAtom *aProperty, [in] nsAString *aAttribute, [in] nsAString *aValue);
2538     nsresult GetInlineProperty([in] nsIAtom *aProperty, [in] nsAString *aAttribute, [in] nsAString *aValue, [out] PRBool *aFirst, [out] PRBool *aAny, [out] PRBool *aAll);
2539     nsresult GetInlinePropertyWithAttrValue([in] nsIAtom *aProperty, [in] nsAString *aAttribute, [in] nsAString *aValue, [out] PRBool *aFirst, [out] PRBool *aAny, [out] PRBool *aAll, [out] nsAString *_retval);
2540     nsresult RemoveAllInlineProperties();
2541     nsresult RemoveInlineProperty([in] nsIAtom *aProperty, [in] nsAString *aAttribute);
2542     nsresult IncreaseFontSize();
2543     nsresult DecreaseFontSize();
2544     nsresult CanDrag([in] nsIDOMEvent *aEvent, [out] PRBool *_retval);
2545     nsresult DoDrag([in] nsIDOMEvent *aEvent);
2546     nsresult InsertFromDrop([in] nsIDOMEvent *aEvent);
2547     nsresult NodeIsBlock([in] nsIDOMNode *node, PRBool *_retval);
2548     nsresult InsertHTML([in] nsAString *aInputString);
2549     nsresult PasteNoFormatting([in] PRInt32 aSelectionType);
2550     nsresult RebuildDocumentFromSource([in] nsAString *aSourceString);
2551     nsresult InsertHTMLWithContext([in] nsAString *aInputString, [in] nsAString *aContextStr, [in] nsAString *aInfoStr, [in] nsAString *aFlavor, [in] nsIDOMDocument *aSourceDoc, [in] nsIDOMNode *aDestinationNode, [in] PRInt32 aDestinationOffset, [in] PRBool aDeleteSelection);
2552     nsresult InsertElementAtSelection([in] nsIDOMElement *aElement, [in] PRBool aDeleteSelection);
2553     nsresult SetDocumentTitle([in] nsAString *aTitle);
2554     nsresult UpdateBaseURL();
2555     nsresult SelectElement([in] nsIDOMElement *aElement);
2556     nsresult SetCaretAfterElement([in] nsIDOMElement *aElement);
2557     nsresult SetParagraphFormat([in] nsAString *aParagraphFormat);
2558     nsresult GetParagraphState([out] PRBool *aMixed, [out] nsAString *_retval);
2559     nsresult GetFontFaceState([out] PRBool *aMixed, [out] nsAString *_retval);
2560     nsresult GetFontColorState([out] PRBool *aMixed, [out] nsAString *_retval);
2561     nsresult GetBackgroundColorState([out] PRBool *aMixed, [out] nsAString *_retval);
2562     nsresult GetHighlightColorState([out] PRBool *aMixed, [out] nsAString *_retval);
2563     nsresult GetListState([out] PRBool *aMixed, [out] PRBool *aOL, [out] PRBool *aUL, [out] PRBool *aDL);
2564     nsresult GetListItemState([out] PRBool *aMixed, [out] PRBool *aLI, [out] PRBool *aDT, [out] PRBool *aDD);
2565     nsresult GetAlignment([out] PRBool *aMixed, [out] PRInt16 *aAlign);
2566     nsresult GetIndentState([out] PRBool *aCanIndent, [out] PRBool *aCanOutdent);
2567     nsresult MakeOrChangeList([in] nsAString *aListType, [in] PRBool entireList, [in] nsAString *aBulletType);
2568     nsresult RemoveList([in] nsAString *aListType);
2569     nsresult Indent([in] nsAString *aIndent);
2570     nsresult Align([in] nsAString *aAlign);
2571     nsresult GetElementOrParentByTagName([in] nsAString *aTagName, [in] nsIDOMNode *aNode, [out] nsIDOMElement **_retval);
2572     nsresult GetSelectedElement([in] nsAString *aTagName, [out] nsIDOMElement **_retval);
2573     nsresult GetHeadContentsAsHTML([out] nsAString *_retval);
2574     nsresult ReplaceHeadContentsWithHTML([in] nsAString *aSourceToInsert);
2575     nsresult CreateElementWithDefaults([in] nsAString *aTagName, [out] nsIDOMElement **_retval);
2576     nsresult InsertLinkAroundSelection([in] nsIDOMElement *aAnchorElement);
2577     nsresult SetBackgroundColor([in] nsAString *aColor);
2578     nsresult SetBodyAttribute([in] nsAString *aAttr, [in] nsAString *aValue);
2579     nsresult IgnoreSpuriousDragEvent([in] PRBool aIgnoreSpuriousDragEvent);
2580     nsresult GetLinkedObjects([out] nsISupportsArray **_retval);
2581     nsresult GetIsCSSEnabled([out] PRBool *_retval);
2582     nsresult SetIsCSSEnabled([in] PRBool prb);
2583     nsresult AddInsertionListener([in] nsIContentFilter *inFilter);
2584     nsresult RemoveInsertionListener([in] nsIContentFilter *inFilter);
2585     nsresult CreateAnonymousElement([in] nsAString *aTag, [in] nsIDOMNode *aParentNode, [in] nsAString *aAnonClass, [in] PRBool aIsCreatedHidden, [out] nsIDOMElement **_retval);
2586     nsresult GetSelectionContainer([out] nsIDOMElement **_retval);
2587     nsresult CheckSelectionStateForAnonymousButtons([in] nsISelection *aSelection);
2588     nsresult IsAnonymousElement([in] nsIDOMElement *aElement, [out] PRBool *_retval);
2589     nsresult GetReturnInParagraphCreatesNewParagraph([out] PRBool *_retval);
2590     nsresult SetReturnInParagraphCreatesNewParagraph([in] PRBool prb);
2591 }
2592
2593 [
2594     object,
2595     uuid(365d600b-868a-452a-8de8-f46fad8fee53),
2596     local
2597     /* NOT_FROZEN */
2598 ]
2599 interface nsIMutationObserver : nsISupports
2600 {
2601     void CharacterDataWillChange(nsIDocument *aDocument, nsIContent *aContent,
2602                                  void /*CharacterDataChangeInfo*/ *aInfo);
2603     void CharacterDataChanged(nsIDocument *aDocument, nsIContent *aContent,
2604                               void /*CharacterDataChangeInfo*/ *aInfo);
2605     void AttributeWillChange(nsIDocument *aDocument, nsIContent * aContent, PRInt32 aNameSpaceID,
2606                              nsIAtom *aAttribute, PRInt32 aModType);
2607     void AttributeChanged(nsIDocument *aDocument, nsIContent *aContent, PRInt32 aNameSpaceID,
2608                           nsIAtom *aAttribute, PRInt32 aModType, PRUint32 aStateMask);
2609     void ContentAppended(nsIDocument *aDocument, nsIContent *aContainer, PRInt32 aNewIndexInContainer);
2610     void ContentInserted(nsIDocument *aDocument, nsIContent *aContainer, nsIContent *aChild,
2611                          PRInt32 aIndexInContainer);
2612     void ContentRemoved(nsIDocument *aDocument, nsIContent *aContainer, nsIContent *aChild,
2613                         PRInt32 aIndexInContainer);
2614     void NodeWillBeDestroyed(const nsINode *aNode);
2615     void ParentChainChanged(nsIContent *aContent);
2616 }
2617
2618 [
2619     object,
2620     uuid(4e14e321-a4bb-49f8-a57a-2363668d14d0),
2621     local
2622     /* NOT_FROZEN */
2623 ]
2624 interface nsIDocumentObserver : nsIMutationObserver
2625 {
2626     typedef int nsUpdateType;
2627
2628     void BeginUpdate(nsIDocument *aDocument, nsUpdateType aUpdateType);
2629     void EndUpdate(nsIDocument *aDocument, nsUpdateType aUpdateType);
2630     void BeginLoad(nsIDocument *aDocument);
2631     void EndLoad(nsIDocument *aDocument);
2632     void ContentStatesChanged(nsIDocument *aDocument, nsIContent *aContent1, nsIContent *aContent2,
2633                               PRInt32 aStateMask);
2634     void StyleSheetAdded(nsIDocument *aDocument, nsIStyleSheet *aStyleSheet, PRBool aDocumentSheet);
2635     void StyleSheetRemoved(nsIDocument *aDocument, nsIStyleSheet *aStyleSheet, PRBool aDocumentSheet);
2636     void StyleSheetApplicableStateChanged(nsIDocument *aDocument, nsIStyleSheet *aStyleSheet,
2637                                           PRBool aApplicable);
2638     void StyleRuleChanged(nsIDocument *aDocument, nsIStyleSheet *aStyleSheet, nsIStyleRule *aOldStyleRule,
2639                           nsIStyleRule *aNewStyleRule);
2640     void StyleRuleAdded(nsIDocument *aDocument, nsIStyleSheet *aStyleSheet, nsIStyleRule *aStyleRule);
2641     void StyleRuleRemoved(nsIDocument *aDocument, nsIStyleSheet *aStyleSheet, nsIStyleRule *aStyleRule);
2642     void BindToDocument(nsIDocument *aDocument, nsIContent *aContent);
2643     void DoneAddingChildren(nsIContent *aContent, PRBool aHaveNotified);
2644 }
2645
2646 /*
2647  * NOTE:
2648  * This is a private Wine interface that is implemented by our implementation
2649  * of nsIURI to store its owner.
2650  */
2651 [
2652     object,
2653     uuid(5088272e-900b-11da-c687-000fea57f21a),
2654     local
2655     /* INTERNAL */
2656 ]
2657 interface nsIWineURI : nsIURL
2658 {
2659     typedef struct NSContainer NSContainer;
2660     typedef struct HTMLWindow HTMLWindow;
2661
2662     nsresult GetNSContainer(NSContainer **aNSContainer);
2663     nsresult SetNSContainer(NSContainer *aNSContainer);
2664     nsresult GetWindow(HTMLWindow **aHTMLWindow);
2665     nsresult SetWindow(HTMLWindow *aHTMLWindow);
2666     nsresult GetIsDocumentURI(PRBool *aIsDocumentURI);
2667     nsresult SetIsDocumentURI(PRBool aIsDocumentURI);
2668     nsresult GetWineURL(LPCWSTR *aURL);
2669     nsresult SetWineURL(LPCWSTR aURL);
2670 }