1 type derived from TaskDialogButton
System.Windows.Forms (1)
System\Windows\Forms\Dialogs\TaskDialog\TaskDialogCommandLinkButton.cs (1)
9
public sealed class TaskDialogCommandLinkButton :
TaskDialogButton
13 instantiations of TaskDialogButton
System.Windows.Forms (13)
System\Windows\Forms\Dialogs\TaskDialog\TaskDialog.cs (1)
296
return new
TaskDialogButton
(result)
System\Windows\Forms\Dialogs\TaskDialog\TaskDialogButton.cs (11)
89
public static TaskDialogButton OK =>
new
(TaskDialogResult.OK);
102
public static TaskDialogButton Cancel =>
new
(TaskDialogResult.Cancel);
107
public static TaskDialogButton Abort =>
new
(TaskDialogResult.Abort);
112
public static TaskDialogButton Retry =>
new
(TaskDialogResult.Retry);
117
public static TaskDialogButton Ignore =>
new
(TaskDialogResult.Ignore);
122
public static TaskDialogButton Yes =>
new
(TaskDialogResult.Yes);
127
public static TaskDialogButton No =>
new
(TaskDialogResult.No);
132
public static TaskDialogButton Close =>
new
(TaskDialogResult.Close);
143
public static TaskDialogButton Help =>
new
(TaskDialogResult.Help);
148
public static TaskDialogButton TryAgain =>
new
(TaskDialogResult.TryAgain);
153
public static TaskDialogButton Continue =>
new
(TaskDialogResult.Continue);
System\Windows\Forms\Dialogs\TaskDialog\TaskDialogButtonCollection.cs (1)
39
TaskDialogButton button =
new
(text, enabled, allowCloseDialog);
89 references to TaskDialogButton
System.Windows.Forms (89)
System\Windows\Forms\Dialogs\TaskDialog\TaskDialog.cs (25)
154
private (
TaskDialogButton
button, int buttonID)? _resultButton;
282
private static bool IsTaskDialogButtonCommitting(
TaskDialogButton
? button)
294
private static
TaskDialogButton
CreatePlaceholderButton(TaskDialogResult result)
318
/// The <see cref="
TaskDialogButton
"/> which was clicked by the user to close the dialog.
326
public static Task<
TaskDialogButton
> ShowDialogAsync(
350
/// The <see cref="
TaskDialogButton
"/> which was clicked by the user to close the dialog.
358
public static Task<
TaskDialogButton
> ShowDialogAsync(
383
/// The <see cref="
TaskDialogButton
"/> which was clicked by the user to close the dialog.
391
public static async Task<
TaskDialogButton
> ShowDialogAsync(
398
var completion = new TaskCompletionSource<
TaskDialogButton
>();
412
TaskDialogButton
result;
447
/// The <see cref="
TaskDialogButton
"/> which was clicked by the user to close the dialog.
455
public static
TaskDialogButton
ShowDialog(
477
/// The <see cref="
TaskDialogButton
"/> which was clicked by the user to close the dialog.
487
public static
TaskDialogButton
ShowDialog(
513
/// The <see cref="
TaskDialogButton
"/> which was clicked by the user to close the dialog.
521
public static unsafe
TaskDialogButton
ShowDialog(
542
/// The <see cref="
TaskDialogButton
"/> which was clicked by the user to close the dialog.
544
private unsafe
TaskDialogButton
ShowDialogInternal(
698
/// Closes the shown task dialog with <see cref="
TaskDialogButton
.Cancel"/> as resulting button.
703
/// <see cref="
TaskDialogButton
.PerformClick"/> method of the
704
/// <see cref="
TaskDialogButton
"/> that you want to set as a result.
708
/// navigation to complete, whereas <see cref="
TaskDialogButton
.PerformClick"/>
710
/// <see cref="
TaskDialogButton
.Click"/> event won't be raised.
1049
TaskDialogButton
? button = _boundPage.GetBoundButtonByID(buttonID);
System\Windows\Forms\Dialogs\TaskDialog\TaskDialogButton.cs (32)
15
/// <see cref="
TaskDialogButton
"/> instances retrieved by static getters like <see cref="OK"/> are
55
/// Initializes a new instance of the <see cref="
TaskDialogButton
"/> class.
63
/// Initializes a new instance of the <see cref="
TaskDialogButton
"/> class
87
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "OK" button.
89
public static
TaskDialogButton
OK => new(TaskDialogResult.OK);
92
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "Cancel" button.
102
public static
TaskDialogButton
Cancel => new(TaskDialogResult.Cancel);
105
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "Abort" button.
107
public static
TaskDialogButton
Abort => new(TaskDialogResult.Abort);
110
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "Retry" button.
112
public static
TaskDialogButton
Retry => new(TaskDialogResult.Retry);
115
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "Ignore" button.
117
public static
TaskDialogButton
Ignore => new(TaskDialogResult.Ignore);
120
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "Yes" button.
122
public static
TaskDialogButton
Yes => new(TaskDialogResult.Yes);
125
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "No" button.
127
public static
TaskDialogButton
No => new(TaskDialogResult.No);
130
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "Close" button.
132
public static
TaskDialogButton
Close => new(TaskDialogResult.Close);
135
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "Help" button.
143
public static
TaskDialogButton
Help => new(TaskDialogResult.Help);
146
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "Try Again" button.
148
public static
TaskDialogButton
TryAgain => new(TaskDialogResult.TryAgain);
151
/// Gets a standard <see cref="
TaskDialogButton
"/> instance representing the "Continue" button.
153
public static
TaskDialogButton
Continue => new(TaskDialogResult.Continue);
231
/// <see cref="
TaskDialogButton
"/> should be shown when displaying
304
public static bool operator ==(
TaskDialogButton
? b1,
TaskDialogButton
? b2)
309
public static bool operator !=(
TaskDialogButton
? b1,
TaskDialogButton
? b2)
355
if (IsStandardButton && obj is
TaskDialogButton
otherButton && otherButton.IsStandardButton)
372
/// Returns a string that represents the current <see cref="
TaskDialogButton
"/> control.
System\Windows\Forms\Dialogs\TaskDialog\TaskDialogButtonCollection.cs (13)
9
/// Represents a collection of <see cref="
TaskDialogButton
"/> objects.
11
public class TaskDialogButtonCollection : Collection<
TaskDialogButton
>
14
private readonly HashSet<
TaskDialogButton
> _itemSet = [];
26
/// Creates and adds a <see cref="
TaskDialogButton
"/> to the collection.
33
/// <returns>The created <see cref="
TaskDialogButton
"/>.</returns>
37
public
TaskDialogButton
Add(string? text, bool enabled = true, bool allowCloseDialog = true)
39
TaskDialogButton
button = new(text, enabled, allowCloseDialog);
57
protected override void SetItem(int index,
TaskDialogButton
item)
66
TaskDialogButton
oldItem = this[index];
97
protected override void InsertItem(int index,
TaskDialogButton
item)
125
TaskDialogButton
oldItem = this[index];
141
foreach (
TaskDialogButton
button in this)
150
private void DenyIfHasOtherCollection(
TaskDialogButton
item)
System\Windows\Forms\Dialogs\TaskDialog\TaskDialogCommandLinkButton.cs (3)
14
/// Initializes a new instance of the <see cref="
TaskDialogButton
"/> class.
21
/// Initializes a new instance of the <see cref="
TaskDialogButton
"/> class
26
/// An additional description text that will be displayed in a separate line when the <see cref="
TaskDialogButton
"/>s
System\Windows\Forms\Dialogs\TaskDialog\TaskDialogPage.cs (16)
56
private
TaskDialogButton
[]? _boundCustomButtons;
57
private Dictionary<int,
TaskDialogButton
>? _boundStandardButtonsByID;
96
/// user clicks the <see cref="
TaskDialogButton
.Help"/> button.
144
public
TaskDialogButton
? DefaultButton { get; set; }
425
/// <see cref="
TaskDialogButton
.Cancel"/> as resulting button by pressing ESC or Alt+F4
426
/// or by clicking the title bar's close button, even if a <see cref="
TaskDialogButton
.Cancel"/>
436
/// button by adding the <see cref="
TaskDialogButton
.Cancel"/> button that has its
437
/// <see cref="
TaskDialogButton
.Visible"/> property set to <see langword="false"/>.
705
internal
TaskDialogButton
? GetBoundButtonByID(int buttonID)
727
_boundStandardButtonsByID!.TryGetValue(buttonID, out
TaskDialogButton
? button);
795
foreach (
TaskDialogButton
button in _buttons)
879
foreach (
TaskDialogButton
standardButton in _boundStandardButtonsByID.Values)
891
TaskDialogButton
customButton = _boundCustomButtons[i];
899
TaskDialogButton
defaultButton = buttons[buttons.IndexOf(DefaultButton)];
975
foreach (
TaskDialogButton
button in buttons)
1023
foreach (
TaskDialogButton
button in buttons)