Mercurial > projects > dwt-mac
comparison dwt/internal/mozilla/nsIPromptService.d @ 45:d8635bb48c7c
Merge with SWT 3.5
author | Jacob Carlborg <doob@me.com> |
---|---|
date | Mon, 01 Dec 2008 17:07:00 +0100 |
parents | |
children | 5583f8eeee6c |
comparison
equal
deleted
inserted
replaced
44:ca5e494f2bbf | 45:d8635bb48c7c |
---|---|
1 /* ***** BEGIN LICENSE BLOCK ***** | |
2 * Version: MPL 1.1 | |
3 * | |
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/ | |
8 * | |
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 | |
12 * License. | |
13 * | |
14 * The Original Code is Mozilla Communicator client code, released March 31, 1998. | |
15 * | |
16 * The Initial Developer of the Original Code is | |
17 * Netscape Communications Corporation. | |
18 * Portions created by Netscape are Copyright (C) 1998-1999 | |
19 * Netscape Communications Corporation. All Rights Reserved. | |
20 * | |
21 * Contributor(s): | |
22 * | |
23 * IBM | |
24 * - Binding to permit interfacing between Mozilla and DWT | |
25 * - Copyright (C) 2003, 2008 IBM Corp. All Rights Reserved. | |
26 * | |
27 * ***** END LICENSE BLOCK ***** */ | |
28 module dwt.internal.mozilla.nsIPromptService; | |
29 | |
30 import dwt.dwthelper.utils; | |
31 | |
32 public class nsIPromptService extends nsISupports { | |
33 | |
34 static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 9; | |
35 | |
36 public static final String NS_IPROMPTSERVICE_IID_STR = | |
37 "1630c61a-325e-49ca-8759-a31b16c47aa5"; | |
38 | |
39 public static final nsID NS_IPROMPTSERVICE_IID = | |
40 new nsID(NS_IPROMPTSERVICE_IID_STR); | |
41 | |
42 public nsIPromptService(int /*long*/ address) { | |
43 super(address); | |
44 } | |
45 | |
46 public int Alert(int /*long*/ aParent, char[] aDialogTitle, char[] aText) { | |
47 return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1, getAddress(), aParent, aDialogTitle, aText); | |
48 } | |
49 | |
50 public int AlertCheck(int /*long*/ aParent, char[] aDialogTitle, char[] aText, char[] aCheckMsg, int[] aCheckState) { | |
51 return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2, getAddress(), aParent, aDialogTitle, aText, aCheckMsg, aCheckState); | |
52 } | |
53 | |
54 public int Confirm(int /*long*/ aParent, char[] aDialogTitle, char[] aText, int[] _retval) { | |
55 return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3, getAddress(), aParent, aDialogTitle, aText, _retval); | |
56 } | |
57 | |
58 public int ConfirmCheck(int /*long*/ aParent, char[] aDialogTitle, char[] aText, char[] aCheckMsg, int[] aCheckState, int[] _retval) { | |
59 return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4, getAddress(), aParent, aDialogTitle, aText, aCheckMsg, aCheckState, _retval); | |
60 } | |
61 | |
62 public static final int BUTTON_POS_0 = 1; | |
63 | |
64 public static final int BUTTON_POS_1 = 256; | |
65 | |
66 public static final int BUTTON_POS_2 = 65536; | |
67 | |
68 public static final int BUTTON_TITLE_OK = 1; | |
69 | |
70 public static final int BUTTON_TITLE_CANCEL = 2; | |
71 | |
72 public static final int BUTTON_TITLE_YES = 3; | |
73 | |
74 public static final int BUTTON_TITLE_NO = 4; | |
75 | |
76 public static final int BUTTON_TITLE_SAVE = 5; | |
77 | |
78 public static final int BUTTON_TITLE_DONT_SAVE = 6; | |
79 | |
80 public static final int BUTTON_TITLE_REVERT = 7; | |
81 | |
82 public static final int BUTTON_TITLE_IS_STRING = 127; | |
83 | |
84 public static final int BUTTON_POS_0_DEFAULT = 0; | |
85 | |
86 public static final int BUTTON_POS_1_DEFAULT = 16777216; | |
87 | |
88 public static final int BUTTON_POS_2_DEFAULT = 33554432; | |
89 | |
90 public static final int BUTTON_DELAY_ENABLE = 67108864; | |
91 | |
92 public static final int STD_OK_CANCEL_BUTTONS = 513; | |
93 | |
94 public static final int STD_YES_NO_BUTTONS = 1027; | |
95 | |
96 public int ConfirmEx(int /*long*/ aParent, char[] aDialogTitle, char[] aText, int aButtonFlags, char[] aButton0Title, char[] aButton1Title, char[] aButton2Title, char[] aCheckMsg, int[] aCheckState, int[] _retval) { | |
97 return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5, getAddress(), aParent, aDialogTitle, aText, aButtonFlags, aButton0Title, aButton1Title, aButton2Title, aCheckMsg, aCheckState, _retval); | |
98 } | |
99 | |
100 public int Prompt(int /*long*/ aParent, char[] aDialogTitle, char[] aText, int /*long*/[] aValue, char[] aCheckMsg, int[] aCheckState, int[] _retval) { | |
101 return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6, getAddress(), aParent, aDialogTitle, aText, aValue, aCheckMsg, aCheckState, _retval); | |
102 } | |
103 | |
104 public int PromptUsernameAndPassword(int /*long*/ aParent, char[] aDialogTitle, char[] aText, int /*long*/[] aUsername, int /*long*/[] aPassword, char[] aCheckMsg, int[] aCheckState, int[] _retval) { | |
105 return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7, getAddress(), aParent, aDialogTitle, aText, aUsername, aPassword, aCheckMsg, aCheckState, _retval); | |
106 } | |
107 | |
108 public int PromptPassword(int /*long*/ aParent, char[] aDialogTitle, char[] aText, int /*long*/[] aPassword, char[] aCheckMsg, int[] aCheckState, int[] _retval) { | |
109 return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8, getAddress(), aParent, aDialogTitle, aText, aPassword, aCheckMsg, aCheckState, _retval); | |
110 } | |
111 | |
112 public int Select(int /*long*/ aParent, char[] aDialogTitle, char[] aText, int aCount, int /*long*/[] aSelectList, int[] aOutSelection, int[] _retval) { | |
113 return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9, getAddress(), aParent, aDialogTitle, aText, aCount, aSelectList, aOutSelection, _retval); | |
114 } | |
115 } |