1 /* ***** BEGIN LICENSE BLOCK *****
2 * Version: MPL 1.1/GPL 2.0/LGPL 2.1
4 * The contents of this file are subject to the Mozilla Public License Version
5 * 1.1 (the "License"); you may not use this file except in compliance with
6 * the License. You may obtain a copy of the License at
7 * http://www.mozilla.org/MPL/
9 * Software distributed under the License is distributed on an "AS IS" basis,
10 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
11 * for the specific language governing rights and limitations under the
14 * The Original Code is nsIWebProgressListener2 interface.
16 * The Initial Developer of the Original Code is
17 * Christian Biesinger <cbiesinger@web.de>.
18 * Portions created by the Initial Developer are Copyright (C) 2005
19 * the Initial Developer. All Rights Reserved.
22 * Mark Pilgrim <pilgrim@gmail.com>
24 * Alternatively, the contents of this file may be used under the terms of
25 * either the GNU General Public License Version 2 or later (the "GPL"), or
26 * the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
27 * in which case the provisions of the GPL or the LGPL are applicable instead
28 * of those above. If you wish to allow use of your version of this file only
29 * under the terms of either the GPL or the LGPL, and not to allow others to
30 * use your version of this file under the terms of the MPL, indicate your
31 * decision by deleting the provisions above and replace them with the notice
32 * and other provisions required by the GPL or the LGPL. If you do not delete
33 * the provisions above, a recipient may use your version of this file under
34 * the terms of any one of the MPL, the GPL or the LGPL.
36 * ***** END LICENSE BLOCK ***** */
38 #include
"nsIWebProgressListener.idl"
41 * An extended version of nsIWebProgressListener.
43 [scriptable
, uuid(dde39de0
-e4e0
-11da
-8ad9
-0800200c9a66
)]
44 interface nsIWebProgressListener2
: nsIWebProgressListener
{
46 * Notification that the progress has changed for one of the requests
47 * associated with aWebProgress. Progress totals are reset to zero when all
48 * requests in aWebProgress complete (corresponding to onStateChange being
49 * called with aStateFlags including the STATE_STOP and STATE_IS_WINDOW
52 * This function is identical to nsIWebProgressListener::onProgressChange,
53 * except that this function supports 64-bit values.
56 * The nsIWebProgress instance that fired the notification.
58 * The nsIRequest that has new progress.
59 * @param aCurSelfProgress
60 * The current progress for aRequest.
61 * @param aMaxSelfProgress
62 * The maximum progress for aRequest.
63 * @param aCurTotalProgress
64 * The current progress for all requests associated with aWebProgress.
65 * @param aMaxTotalProgress
66 * The total progress for all requests associated with aWebProgress.
68 * NOTE: If any progress value is unknown, then its value is replaced with -1.
70 * @see nsIWebProgressListener2::onProgressChange64
72 void onProgressChange64
(in nsIWebProgress aWebProgress
,
73 in nsIRequest aRequest
,
74 in long long aCurSelfProgress
,
75 in long long aMaxSelfProgress
,
76 in long long aCurTotalProgress
,
77 in long long aMaxTotalProgress
);
80 * Notification that a refresh or redirect has been requested in aWebProgress
81 * For example, via a <meta http-equiv="refresh"> or an HTTP Refresh: header
84 * The nsIWebProgress instance that fired the notification.
86 * The new URI that aWebProgress has requested redirecting to.
88 * The delay (in milliseconds) before refresh.
90 * True if aWebProgress is requesting a refresh of the
92 * False if aWebProgress is requesting a redirection to
95 * @return True if the refresh may proceed.
96 * False if the refresh should be aborted.
98 boolean onRefreshAttempted
(in nsIWebProgress aWebProgress
,
99 in nsIURI aRefreshURI
,
101 in boolean aSameURI
);