InputType.Password enabled for prompt dialog

This commit is contained in:
Vladimir Enchev
2014-06-09 17:13:00 +03:00
parent 37afd97cb0
commit f577816d1e
5 changed files with 70 additions and 31 deletions

View File

@@ -1,6 +1,9 @@
declare module "ui/dialogs" {
import promises = require("promises");
import view = require("ui/core/view");
import dialogs_common = require("ui/dialogs/dialogs-common");
export var InputType: dialogs_common.InputType;
/**
* The alert() method displays an alert box with a specified message.
@@ -21,7 +24,7 @@
* @param message The text to display in the dialog box.
* @param options The options for the dialog box. Optional.
*/
function prompt(message: string, defaultText?: string, options?: DialogButtonsOptions): promises.Promise<string>;
function prompt(message: string, defaultText?: string, options?: PromptOptions): promises.Promise<string>;
/**
* Provides options for the dialog.
@@ -44,7 +47,7 @@
}
/**
* Provides options for the confirm.
* Provides options for the confirm dialog.
*/
interface DialogButtonsOptions extends AlertOptions {
/**
@@ -58,6 +61,16 @@
neutralButtonText?: string;
}
/**
* Provides options for the prompt dialog.
*/
interface PromptOptions extends DialogButtonsOptions {
/**
* Gets or sets the prompt input type (plain text or password).
*/
inputType?: dialogs_common.InputType;
}
/**
* Provides result data from the prompt dialog.
*/