//..............................................................................
//
// Ninja standard dialogs
//

namespace gui {

//..............................................................................

enum StdDlgIcon
{
	None,
	Info,
	Warning,
	Error,
}

// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

enum StdDlgButton
{
	Ok,
	Cancel,
	Yes,
	No,
	Abort,
	Retry,
	Close,
}

// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

bitflag enum StdDlgButtons
{
	Ok,
	Cancel,
	Yes,
	No,
	Abort,
	Retry,
	Close,
}

//..............................................................................

enum FileDlgKind
{
	Open,
	Save,
}

// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

opaque class FileDlg
{
	FileDlgKind autoget property m_kind;
	char const* autoget property m_title;
	char const* autoget property m_filter;
	char const* autoget property m_filePath;

	event m_onCompleted (StdDlgButton button);

	construct ();

	show ();
}

//..............................................................................

enum AuthenticationMethod
{
	Password,
	PrivateKey,
}

// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

opaque class LoginDlg
{
	char const* autoget property m_title;
	char const* autoget property m_message;
	char const* autoget property m_userName;

	AuthenticationMethod autoget property m_authenticationMethod;
	char const* autoget property m_password;
	char const* autoget property m_privateKeyFileName;
	char const* autoget property m_privateKeyPassphrase;

	event m_onCompleted (StdDlgButton button);

	construct ();

	show ();
}

//..............................................................................

opaque class MessageDlg
{
	char const* autoget property m_title;
	char const* autoget property m_message;
	StdDlgIcon autoget property m_icon;
	StdDlgButtons autoget property m_buttons;

	event m_onCompleted (StdDlgButton button);

	construct ();

	show ();
}

//..............................................................................

opaque class ProgressDlg
{
	char const* autoget property m_title;
	char const* autoget property m_status;
	int autoget property m_progress;
	StdDlgIcon autoget property m_icon;
	StdDlgButtons autoget property m_buttons;

	event m_onButtonClicked (StdDlgButton button);

	construct ();

	show ();
	hide ();
}

//..............................................................................

} // namespace gui {
