embedding/components/windowwatcher/public/nsIPromptService2.idl

changeset 0
6474c204b198
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/embedding/components/windowwatcher/public/nsIPromptService2.idl	Wed Dec 31 06:09:35 2014 +0100
     1.3 @@ -0,0 +1,45 @@
     1.4 +/* This Source Code Form is subject to the terms of the Mozilla Public
     1.5 + * License, v. 2.0. If a copy of the MPL was not distributed with this
     1.6 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
     1.7 +
     1.8 +#include "nsIPromptService.idl"
     1.9 +
    1.10 +interface nsIAuthInformation;
    1.11 +interface nsIAuthPromptCallback;
    1.12 +interface nsICancelable;
    1.13 +interface nsIChannel;
    1.14 +interface nsIDOMWindow;
    1.15 +
    1.16 +/**
    1.17 + * This is an improved version of nsIPromptService that is less prescriptive
    1.18 + * about the resulting user interface.
    1.19 + *
    1.20 + * @status INCOMPLETE do not freeze before fixing bug 228207
    1.21 + */
    1.22 +[scriptable, uuid(cf86d196-dbee-4482-9dfa-3477aa128319)]
    1.23 +interface nsIPromptService2 : nsIPromptService {
    1.24 +  // NOTE: These functions differ from their nsIAuthPrompt counterparts by
    1.25 +  // having additional checkbox parameters
    1.26 +  // checkValue can be null meaning to show no checkbox
    1.27 +  // checkboxLabel is a wstring so that it can be null from both JS and C++ in
    1.28 +  // a convenient way
    1.29 +  //
    1.30 +  // See nsIAuthPrompt2 for documentation on the semantics of the other
    1.31 +  // parameters.
    1.32 +  boolean promptAuth(in nsIDOMWindow aParent,
    1.33 +                     in nsIChannel aChannel,
    1.34 +                     in uint32_t level,
    1.35 +                     in nsIAuthInformation authInfo,
    1.36 +                     in wstring checkboxLabel,
    1.37 +                     inout boolean checkValue);
    1.38 +
    1.39 +  nsICancelable asyncPromptAuth(in nsIDOMWindow aParent,
    1.40 +                                in nsIChannel aChannel,
    1.41 +                                in nsIAuthPromptCallback aCallback,
    1.42 +                                in nsISupports aContext,
    1.43 +                                in uint32_t level,
    1.44 +                                in nsIAuthInformation authInfo,
    1.45 +                                in wstring checkboxLabel,
    1.46 +                                inout boolean checkValue);
    1.47 +};
    1.48 +

mercurial