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