~ubuntu-branches/ubuntu/precise/kompozer/precise

« back to all changes in this revision

Viewing changes to mozilla/content/base/public/nsIScriptLoaderObserver.idl

  • Committer: Bazaar Package Importer
  • Author(s): Anthony Yarusso
  • Date: 2007-08-27 01:11:03 UTC
  • Revision ID: james.westby@ubuntu.com-20070827011103-2jgf4s6532gqu2ka
Tags: upstream-0.7.10
ImportĀ upstreamĀ versionĀ 0.7.10

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 
2
/*
 
3
 * The contents of this file are subject to the Mozilla Public
 
4
 * License Version 1.1 (the "License"); you may not use this file
 
5
 * except in compliance with the License. You may obtain a copy of
 
6
 * the License at http://www.mozilla.org/MPL/
 
7
 * 
 
8
 * Software distributed under the License is distributed on an "AS
 
9
 * IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
 
10
 * implied. See the License for the specific language governing
 
11
 * rights and limitations under the License.
 
12
 * 
 
13
 * The Original Code is Mozilla.
 
14
 * 
 
15
 * The Initial Developer of the Original Code is Netscape
 
16
 * Communications.  Portions created by Netscape Communications are
 
17
 * Copyright (C) 2001 by Netscape Communications.  All
 
18
 * Rights Reserved.
 
19
 * 
 
20
 * Contributor(s): 
 
21
 *   Vidur Apparao <vidur@netscape.com> (original author)
 
22
 */
 
23
 
 
24
#include "nsISupports.idl"
 
25
 
 
26
interface nsIDOMHTMLScriptElement;
 
27
interface nsIURI;
 
28
 
 
29
[scriptable, uuid(501209d3-7edf-437d-9948-3c6d1c08ef7f)]
 
30
interface nsIScriptLoaderObserver : nsISupports {
 
31
  
 
32
  /**
 
33
   * The script is available for evaluation. For inline scripts, this
 
34
   * method will be called synchronously. For externally loaded scripts,
 
35
   * this method will be called when the load completes.
 
36
   *
 
37
   * @param aResult A result code representing the result of loading
 
38
   *        a script. If this is a failure code, script evaluation
 
39
   *        will not occur.
 
40
   * @param aElement The element being processed.
 
41
   * @param aIsInline Is this an inline script or externally loaded?
 
42
   * @param aWasPending Did script processing have to be delayed,
 
43
   *                    either for loading of an external script or
 
44
   *                    because processing of an earlier scheduled
 
45
   *                    script was delayed?
 
46
   * @param aURI What is the URI of the script (the document URI if
 
47
   *        it is inline).
 
48
   * @param aLineNo At what line does the script appear (generally 1
 
49
   *        if it is a loaded script).
 
50
   * @param aScript String representation of the string to be evaluated.
 
51
   */
 
52
  void scriptAvailable(in nsresult aResult, 
 
53
                       in nsIDOMHTMLScriptElement aElement,
 
54
                       in boolean aIsInline,
 
55
                       in boolean aWasPending,
 
56
                       in nsIURI aURI,
 
57
                       in PRInt32 aLineNo,
 
58
                       in AString aScript);
 
59
 
 
60
  /**
 
61
   * The script has been evaluated.
 
62
   *
 
63
   * @param aResult A result code representing the success or failure of
 
64
   *        the script evaluation.
 
65
   * @param aElement The element being processed.
 
66
   * @param aIsInline Is this an inline script or externally loaded?
 
67
   * @param aWasPending Did script processing have to be delayed,
 
68
   *                    either for loading of an external script or
 
69
   *                    because processing of an earlier scheduled
 
70
   *                    script was delayed?
 
71
   */
 
72
  void scriptEvaluated(in nsresult aResult, 
 
73
                       in nsIDOMHTMLScriptElement aElement,
 
74
                       in boolean aIsInline,
 
75
                       in boolean aWasPending);
 
76
                       
 
77
};