// Copyright (c) Pixel Crushers. All rights reserved.
using System;
namespace PixelCrushers.DialogueSystem
{
///
/// This delegate is called when the player accepts the input.
///
public delegate void AcceptedTextDelegate(string text);
///
/// Interface for text field UI components. Components implementing this interface
/// should provide a GUI control for entering text.
///
/// See UnityTextFieldUI for a reference implementation that uses Unity GUI.
///
public interface ITextFieldUI
{
///
/// Called to display the text field and start handling input. When the user accepts the input
/// (e.g., by pressing the Return key), call the acceptedText delegate.
///
void StartTextInput(string labelText, string text, int maxLength, AcceptedTextDelegate acceptedText);
///
/// Called to force the text field to cancel.
///
void CancelTextInput();
}
}