| Package | com.hippohx |
| Class | public class Dialog |
| Inheritance | Dialog HaxeBackendListener flash.events.EventDispatcher |
| Method | Defined by | ||
|---|---|---|---|
|
Dialog()
Do NOT call this constructor, please use getInstance method instead.
| Dialog | ||
|
confirm(title:String, msg:String, isError:Boolean = false):Boolean
Displays system's confirmation dialog to the user.
| Dialog | ||
![]() |
getHaxeBackendId():String
Returns HAXE_BACKEND API identifier.
| HaxeBackendListener | |
|
[static]
Use this method to retrieve an instance of the class, do NOT call the constructor directly.
| Dialog | ||
|
message(title:String, msg:String, isError:Boolean = false):void
Displays system's dialog message to the user.
| Dialog | ||
|
openFile(title:String, msg:String, mask:DialogMask = null):Array
Opens system's select file dialog.
| Dialog | ||
|
saveFile(title:String, msg:String, initialDir:String = null):String
Opens system's save file dialog.
| Dialog | ||
|
selectFolder(title:String, msg:String):String
Opens system's select folder dialog.
| Dialog | ||
| Dialog | () | constructor |
public function Dialog()Do NOT call this constructor, please use getInstance method instead.
See also
| confirm | () | method |
public function confirm(title:String, msg:String, isError:Boolean = false):BooleanDisplays system's confirmation dialog to the user.
Neko call is systools.Dialogs.confirm(title,msg,isError).
Parameterstitle:String — Title shown on the dialog.
|
|
msg:String — Message shown on the dialog.
|
|
isError:Boolean (default = false) — Determines if the dialog is shown to the user as a regular message or as an error (usually comes with system's error sound). Default value is false.
|
Boolean — true if the user clicks on "Yes", false otherwise.
|
| getInstance | () | method |
public static function getInstance():DialogUse this method to retrieve an instance of the class, do NOT call the constructor directly. Note that you don't need to store the instance to access its methods, you can simply do this:
Dialog.getInstance().message("Title","Message");
Dialog |
| message | () | method |
public function message(title:String, msg:String, isError:Boolean = false):voidDisplays system's dialog message to the user.
Neko call is systools.Dialogs.message(title,msg,isError).
Parameterstitle:String — Title shown on the dialog.
|
|
msg:String — Message shown on the dialog.
|
|
isError:Boolean (default = false) — Determines if the dialog is shown to the user as a regular message or as an error (usually comes with system's error sound). Default value is false.
|
| openFile | () | method |
public function openFile(title:String, msg:String, mask:DialogMask = null):ArrayOpens system's select file dialog. Use this dialog when you want to allow the user to select files that are alreday present on the system. Please note that this method only returns path to files, not the content of the files themselves.
Neko call is systools.Dialogs.openFile(title,msg,mask).
Parameterstitle:String — Title shown on the dialog.
|
|
msg:String — Message shown on the dialog.
|
|
mask:DialogMask (default = null) — The mask filters what type of files are shown on the dialog. That means you can force the dialog to only show certain file types such as swfs, jpgs, xmls or any other. Default value is "all files" using AllFilesDialogMask class. You can use your own masks creating a new DialogMask object.
|
Array — An Array with full paths to the files selected by the user. Currently you cannot force a single-file selection dialog.
|
See also
| saveFile | () | method |
public function saveFile(title:String, msg:String, initialDir:String = null):StringOpens system's save file dialog. Use this dialog when you want to allow the user to create a new file or select one that has been already created to overwrite it. Please note that this method only returns the path to the file, it doesn't actually save or overwrite it.
Neko call is systools.Dialogs.saveFile(title,msg,initialDir).
Parameterstitle:String — Title shown on the dialog.
|
|
msg:String — Message shown on the dialog.
|
|
initialDir:String (default = null) — The folder in which the dialog is opened, default value is determined by System.getUserFolder(). You could for example start the dialog in your application's folder like this:
|
String — The path to the file selected by the user. null if the dialog is cancelled.
|
See also
| selectFolder | () | method |
public function selectFolder(title:String, msg:String):StringOpens system's select folder dialog.
Neko call is systools.Dialogs.folder(title,msg).
Parameterstitle:String — Title shown on the dialog.
|
|
msg:String — Message shown on the dialog.
|
String — The path to the folder selected by the user. null if the dialog is cancelled.
|