Skip to content

Commit

Permalink
ContentDialog - supports Min\Max sizes (#5872)
Browse files Browse the repository at this point in the history
* ContentDialog - supports Min\Max sizes

* update verification files

Co-authored-by: Alex Didenko <alexander.didenko@devexress.com>
Co-authored-by: Karen Lai <biilai@microsoft.com>
  • Loading branch information
3 people authored Nov 10, 2021
1 parent feb7029 commit bfecc00
Show file tree
Hide file tree
Showing 7 changed files with 745 additions and 9 deletions.
12 changes: 8 additions & 4 deletions dev/CommonStyles/ContentDialog_themeresources.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,10 @@
<Setter Property="PrimaryButtonStyle" Value="{ThemeResource DefaultButtonStyle}" />
<Setter Property="SecondaryButtonStyle" Value="{ThemeResource DefaultButtonStyle}" />
<Setter Property="CloseButtonStyle" Value="{ThemeResource DefaultButtonStyle}" />
<Setter Property="MinWidth" Value="{ThemeResource ContentDialogMinWidth}" />
<Setter Property="MaxWidth" Value="{ThemeResource ContentDialogMaxWidth}" />
<Setter Property="MinHeight" Value="{ThemeResource ContentDialogMinHeight}" />
<Setter Property="MaxHeight" Value="{ThemeResource ContentDialogMaxHeight}" />
<contract7Present:Setter Property="CornerRadius" Value="{ThemeResource OverlayCornerRadius}" />
<Setter Property="Template">
<Setter.Value>
Expand Down Expand Up @@ -242,10 +246,10 @@
BorderBrush="{TemplateBinding BorderBrush}"
contract7Present:BackgroundSizing="InnerBorderEdge"
contract7Present:CornerRadius="{TemplateBinding CornerRadius}"
MinWidth="{ThemeResource ContentDialogMinWidth}"
MaxWidth="{ThemeResource ContentDialogMaxWidth}"
MinHeight="{ThemeResource ContentDialogMinHeight}"
MaxHeight="{ThemeResource ContentDialogMaxHeight}"
MinWidth="{TemplateBinding MinWidth}"
MaxWidth="{TemplateBinding MaxWidth}"
MinHeight="{TemplateBinding MinHeight}"
MaxHeight="{TemplateBinding MaxHeight}"
HorizontalAlignment="Center"
VerticalAlignment="Center"
RenderTransformOrigin="0.5,0.5">
Expand Down
12 changes: 8 additions & 4 deletions dev/CommonStyles/ContentDialog_themeresources_v1.xaml
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,10 @@
<Setter Property="PrimaryButtonStyle" Value="{ThemeResource DefaultButtonStyle}" />
<Setter Property="SecondaryButtonStyle" Value="{ThemeResource DefaultButtonStyle}" />
<Setter Property="CloseButtonStyle" Value="{ThemeResource DefaultButtonStyle}" />
<Setter Property="MinWidth" Value="{ThemeResource ContentDialogMinWidth}" />
<Setter Property="MaxWidth" Value="{ThemeResource ContentDialogMaxWidth}" />
<Setter Property="MinHeight" Value="{ThemeResource ContentDialogMinHeight}" />
<Setter Property="MaxHeight" Value="{ThemeResource ContentDialogMaxHeight}" />
<contract7Present:Setter Property="CornerRadius" Value="{ThemeResource OverlayCornerRadius}" />
<Setter Property="Template">
<Setter.Value>
Expand Down Expand Up @@ -287,10 +291,10 @@
BorderBrush="{TemplateBinding BorderBrush}"
contract7Present:CornerRadius="{TemplateBinding CornerRadius}"
contract7NotPresent:CornerRadius="{ThemeResource OverlayCornerRadius}"
MinWidth="{ThemeResource ContentDialogMinWidth}"
MaxWidth="{ThemeResource ContentDialogMaxWidth}"
MinHeight="{ThemeResource ContentDialogMinHeight}"
MaxHeight="{ThemeResource ContentDialogMaxHeight}"
MinWidth="{TemplateBinding MinWidth}"
MaxWidth="{TemplateBinding MaxWidth}"
MinHeight="{TemplateBinding MinHeight}"
MaxHeight="{TemplateBinding MaxHeight}"
HorizontalAlignment="Center"
VerticalAlignment="Center"
RenderTransformOrigin="0.5,0.5">
Expand Down
4 changes: 3 additions & 1 deletion test/MUXControlsTestApp/verification/ContentDialog-4.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,10 @@
Margin=0,0,0,0
MaxHeight=756
MaxWidth=548
MinHeight=184
MinWidth=320
Padding=0,0,0,0
RenderSize=0,0
RenderSize=320,184
Visibility=Visible
[Windows.UI.Xaml.Controls.Border]
Background=[NULL]
Expand Down
4 changes: 4 additions & 0 deletions test/MUXControlsTestApp/verification/ContentDialog-5.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@
FocusVisualSecondaryThickness=1,1,1,1
Foreground=#E4000000
Margin=0,0,0,0
MaxHeight=756
MaxWidth=548
MinHeight=184
MinWidth=320
Padding=0,0,0,0
RenderSize=0,0
Visibility=Visible
Expand Down
Loading

0 comments on commit bfecc00

Please sign in to comment.