make dialog window not evil (#24677)
* add Placeholder and make default buttons flags consistent w old behaviour * DialogWindow ops * make QuickDialog use DialogWindow * Update Content.Client/UserInterface/Controls/DialogWindow.xaml --------- Co-authored-by: deltanedas <@deltanedas:kde.org> Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
This commit is contained in:
@@ -26,7 +26,7 @@ public sealed class QuickDialogOpenEvent : EntityEventArgs
|
||||
/// <summary>
|
||||
/// The buttons presented for the user.
|
||||
/// </summary>
|
||||
public QuickDialogButtonFlag Buttons = QuickDialogButtonFlag.OkButton;
|
||||
public QuickDialogButtonFlag Buttons = QuickDialogButtonFlag.OkButton | QuickDialogButtonFlag.CancelButton;
|
||||
|
||||
public QuickDialogOpenEvent(string title, List<QuickDialogEntry> prompts, int dialogId, QuickDialogButtonFlag buttons)
|
||||
{
|
||||
@@ -87,11 +87,17 @@ public sealed class QuickDialogEntry
|
||||
/// </summary>
|
||||
public string Prompt;
|
||||
|
||||
public QuickDialogEntry(string fieldId, QuickDialogEntryType type, string prompt)
|
||||
/// <summary>
|
||||
/// String to replace the type-specific placeholder with.
|
||||
/// </summary>
|
||||
public string? Placeholder;
|
||||
|
||||
public QuickDialogEntry(string fieldId, QuickDialogEntryType type, string prompt, string? placeholder = null)
|
||||
{
|
||||
FieldId = fieldId;
|
||||
Type = type;
|
||||
Prompt = prompt;
|
||||
Placeholder = placeholder;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user