Table of Contents


Inherits: AlertDialog

Supported platforms:

Available since version: Gideros 2012.8


The TextInputDialog class is used to display native text input dialogs with one text edit field, one button (as cancel button) and two optional buttons. When the user presses any buttons in the alert dialog, it's dismissed and Event.COMPLETE event is dispatched.
If text input dialog is dismissed by any other means (by pressing back button on Android or by pressing close button on desktop), it behaves as cancel button is pressed.

Common uses and examples:

local textInputDialog ="my title", "my message", "some text", "Cancel", "OK")

local function onComplete(event)
	print(event.text, event.buttonIndex, event.buttonText)

textInputDialog:addEventListener(Event.COMPLETE, onComplete)

Methods, events and properties: