C# Class FirstFloor.ModernUI.Windows.Controls.ModernDialog

Represents a Modern UI styled dialog window.
Inheritance: DpiAwareWindow
ファイルを表示 Open project: gro-ove/actools Class Usage Examples

Public Properties

Property Type Description
BackgroundContentProperty System.Windows.DependencyProperty
ButtonsProperty System.Windows.DependencyProperty
ButtonsRowContentProperty System.Windows.DependencyProperty
IconSourceProperty System.Windows.DependencyProperty

Public Methods

Method Description
CreateCloseDialogButton ( string content, bool isDefault, bool isCancel, MessageBoxResult result, ICommand command = null ) : System.Windows.Controls.Button
CreateExtraDialogButton ( string content, System.Action action ) : System.Windows.Controls.Button
CreateExtraDialogButton ( string content, System.Action action, Func canExecute ) : System.Windows.Controls.Button
CreateExtraDialogButton ( string content, ICommand command, bool isDefault = false ) : System.Windows.Controls.Button
CreateExtraStyledDialogButton ( [ styleKey, string content, System.Action action, Func canExecute = null ) : System.Windows.Controls.Button
CreateExtraStyledDialogButton ( string styleKey, string content, ICommand command ) : System.Windows.Controls.Button
CreateStyledCloseDialogButton ( string styleKey, string content, bool isDefault, bool isCancel, MessageBoxResult result, System.Action action = null ) : System.Windows.Controls.Button
ModernDialog ( ) : System

Initializes a new instance of the ModernDialog class.

ShowMessage ( string text ) : MessageBoxResult
ShowMessage ( string text, string title, MessageBoxButton button, Window owner = null ) : MessageBoxResult

Displays a messagebox.

Protected Methods

Method Description
CloseWithResult ( MessageBoxResult result ) : void

Private Methods

Method Description
GetButtons ( ModernDialog owner, MessageBoxButton button ) : IEnumerable

Method Details

CloseWithResult() protected method

protected CloseWithResult ( MessageBoxResult result ) : void
result MessageBoxResult
return void

CreateCloseDialogButton() public method

public CreateCloseDialogButton ( string content, bool isDefault, bool isCancel, MessageBoxResult result, ICommand command = null ) : System.Windows.Controls.Button
content string
isDefault bool
isCancel bool
result MessageBoxResult
command ICommand
return System.Windows.Controls.Button

CreateExtraDialogButton() public static method

public static CreateExtraDialogButton ( string content, System.Action action ) : System.Windows.Controls.Button
content string
action System.Action
return System.Windows.Controls.Button

CreateExtraDialogButton() public static method

public static CreateExtraDialogButton ( string content, System.Action action, Func canExecute ) : System.Windows.Controls.Button
content string
action System.Action
canExecute Func
return System.Windows.Controls.Button

CreateExtraDialogButton() public static method

public static CreateExtraDialogButton ( string content, ICommand command, bool isDefault = false ) : System.Windows.Controls.Button
content string
command ICommand
isDefault bool
return System.Windows.Controls.Button

CreateExtraStyledDialogButton() public method

public CreateExtraStyledDialogButton ( [ styleKey, string content, System.Action action, Func canExecute = null ) : System.Windows.Controls.Button
styleKey [
content string
action System.Action
canExecute Func
return System.Windows.Controls.Button

CreateExtraStyledDialogButton() public method

public CreateExtraStyledDialogButton ( string styleKey, string content, ICommand command ) : System.Windows.Controls.Button
styleKey string
content string
command ICommand
return System.Windows.Controls.Button

CreateStyledCloseDialogButton() public method

public CreateStyledCloseDialogButton ( string styleKey, string content, bool isDefault, bool isCancel, MessageBoxResult result, System.Action action = null ) : System.Windows.Controls.Button
styleKey string
content string
isDefault bool
isCancel bool
result MessageBoxResult
action System.Action
return System.Windows.Controls.Button

ModernDialog() public method

Initializes a new instance of the ModernDialog class.
public ModernDialog ( ) : System
return System

ShowMessage() public static method

public static ShowMessage ( string text ) : MessageBoxResult
text string
return MessageBoxResult

ShowMessage() public static method

Displays a messagebox.
public static ShowMessage ( string text, string title, MessageBoxButton button, Window owner = null ) : MessageBoxResult
text string The text.
title string The title.
button MessageBoxButton The button.
owner System.Windows.Window The window owning the messagebox. The messagebox will be located at the center of the owner.
return MessageBoxResult

Property Details

BackgroundContentProperty public_oe static_oe property

Identifies the BackgroundContent dependency property.
public static DependencyProperty,System.Windows BackgroundContentProperty
return System.Windows.DependencyProperty

ButtonsProperty public_oe static_oe property

Identifies the Buttons dependency property.
public static DependencyProperty,System.Windows ButtonsProperty
return System.Windows.DependencyProperty

ButtonsRowContentProperty public_oe static_oe property

public static DependencyProperty,System.Windows ButtonsRowContentProperty
return System.Windows.DependencyProperty

IconSourceProperty public_oe static_oe property

public static DependencyProperty,System.Windows IconSourceProperty
return System.Windows.DependencyProperty