mirror of
https://github.com/PrismLibrary/Prism.git
synced 2026-10-29 05:26:34 +08:00
27 lines
1.3 KiB
XML
27 lines
1.3 KiB
XML
<UserControl x:Class="HelloWorld.Dialogs.NotificationDialog"
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
xmlns:prism="http://prismlibrary.com/"
|
|
prism:ViewModelLocator.AutoWireViewModel="True"
|
|
Width="300" Height="150">
|
|
|
|
<prism:Dialog.WindowStyle>
|
|
<Style TargetType="Window">
|
|
<Setter Property="prism:Dialog.WindowStartupLocation" Value="CenterScreen" />
|
|
<Setter Property="ResizeMode" Value="NoResize"/>
|
|
<Setter Property="ShowInTaskbar" Value="False"/>
|
|
<Setter Property="SizeToContent" Value="WidthAndHeight"/>
|
|
</Style>
|
|
</prism:Dialog.WindowStyle>
|
|
|
|
<Grid x:Name="LayoutRoot" Margin="5">
|
|
<Grid.RowDefinitions>
|
|
<RowDefinition />
|
|
<RowDefinition Height="Auto" />
|
|
</Grid.RowDefinitions>
|
|
|
|
<TextBlock Text="{Binding Message}" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Grid.Row="0" TextWrapping="Wrap" />
|
|
<Button Command="{Binding CloseDialogCommand}" CommandParameter="True" Content="OK" Width="75" Height="25" HorizontalAlignment="Right" Margin="0,10,0,0" Grid.Row="1" IsDefault="True" />
|
|
</Grid>
|
|
</UserControl>
|