|
26 | 26 | </Setter> |
27 | 27 | </Style> |
28 | 28 |
|
| 29 | + <system:Double x:Key="PopupContentPresenterExtend">4</system:Double> |
| 30 | + <system:Double x:Key="PopupTopBottomMargin">8</system:Double> |
| 31 | + <system:Double x:Key="PopupLeftRightMargin">16</system:Double> |
29 | 32 |
|
30 | 33 | <ControlTemplate x:Key="PopupContentUpTemplate" TargetType="ContentControl"> |
31 | 34 | <Grid MinWidth="{Binding ElementName=templateRoot, Path=ActualWidth, Converter={StaticResource MathAddConverter}, ConverterParameter=32}" |
|
50 | 53 | <RowDefinition Height="Auto"/> |
51 | 54 | </Grid.RowDefinitions> |
52 | 55 | <Rectangle Grid.Row="0" |
53 | | - Fill="{DynamicResource MaterialDesignPaper}" |
54 | | - Height="8"/> |
55 | | - |
| 56 | + Fill="{DynamicResource MaterialDesignPaper}" |
| 57 | + Height="{StaticResource PopupTopBottomMargin}"/> |
56 | 58 | <ContentPresenter Grid.Row="1"/> |
57 | | - |
58 | 59 | <Rectangle Grid.Row="2" |
59 | | - Fill="{DynamicResource MaterialDesignPaper}" |
60 | | - Height="4"/> |
| 60 | + Fill="{DynamicResource MaterialDesignPaper}" |
| 61 | + Height="{StaticResource PopupContentPresenterExtend}"/> |
61 | 62 |
|
62 | 63 | <Grid Grid.Row="3"> |
63 | 64 | <Grid.ColumnDefinitions> |
|
66 | 67 | <ColumnDefinition Width="*"/> |
67 | 68 | </Grid.ColumnDefinitions> |
68 | 69 | <Rectangle Grid.Column="0" |
69 | | - Width="16" |
70 | | - Fill="{DynamicResource MaterialDesignPaper}"/> |
| 70 | + Width="{StaticResource PopupLeftRightMargin}" |
| 71 | + Fill="{DynamicResource MaterialDesignPaper}"/> |
71 | 72 | <Grid Grid.Column="1" |
72 | | - Width="{Binding ElementName=templateRoot, Path=ActualWidth}" |
73 | | - Height="{Binding ElementName=templateRoot, Path=ActualHeight}"/> |
| 73 | + Width="{Binding ElementName=templateRoot, Path=ActualWidth}" |
| 74 | + Height="{Binding ElementName=templateRoot, Path=ActualHeight}"/> |
74 | 75 | <Rectangle Grid.Column="2" |
75 | | - MinWidth="16" |
76 | | - Fill="{DynamicResource MaterialDesignPaper}"/> |
| 76 | + MinWidth="{StaticResource PopupLeftRightMargin}" |
| 77 | + Fill="{DynamicResource MaterialDesignPaper}"/> |
77 | 78 | </Grid> |
78 | 79 |
|
79 | 80 | <Rectangle Grid.Row="4" |
80 | | - Height="8" |
81 | | - Fill="{DynamicResource MaterialDesignPaper}" /> |
| 81 | + Height="{StaticResource PopupTopBottomMargin}" |
| 82 | + Fill="{DynamicResource MaterialDesignPaper}" /> |
82 | 83 | </Grid> |
83 | 84 | </Grid> |
84 | 85 | </ControlTemplate> |
|
107 | 108 | </Grid.RowDefinitions> |
108 | 109 | <Rectangle Grid.Row="0" |
109 | 110 | Fill="{DynamicResource MaterialDesignPaper}" |
110 | | - Height="8"/> |
| 111 | + Height="{StaticResource PopupTopBottomMargin}"/> |
111 | 112 |
|
112 | 113 | <Grid Grid.Row="1"> |
113 | 114 | <Grid.ColumnDefinitions> |
|
116 | 117 | <ColumnDefinition Width="*"/> |
117 | 118 | </Grid.ColumnDefinitions> |
118 | 119 | <Rectangle Grid.Column="0" |
119 | | - Width="16" |
| 120 | + Width="{StaticResource PopupLeftRightMargin}" |
120 | 121 | Fill="{DynamicResource MaterialDesignPaper}"/> |
121 | 122 | <Grid Grid.Column="1" |
122 | 123 | Width="{Binding ElementName=templateRoot, Path=ActualWidth}" |
123 | 124 | Height="{Binding ElementName=templateRoot, Path=ActualHeight}"/> |
124 | 125 | <Rectangle Grid.Column="2" |
125 | | - MinWidth="16" |
| 126 | + MinWidth="{StaticResource PopupLeftRightMargin}" |
126 | 127 | Fill="{DynamicResource MaterialDesignPaper}"/> |
127 | 128 | </Grid> |
128 | 129 |
|
129 | 130 | <Rectangle Grid.Row="2" |
130 | 131 | Fill="{DynamicResource MaterialDesignPaper}" |
131 | | - Height="4"/> |
| 132 | + Height="{StaticResource PopupContentPresenterExtend}"/> |
132 | 133 |
|
133 | 134 | <ContentPresenter Grid.Row="3"/> |
134 | 135 |
|
135 | 136 | <Rectangle Grid.Row="4" |
136 | | - Height="8" |
| 137 | + Height="{StaticResource PopupTopBottomMargin}" |
137 | 138 | Fill="{DynamicResource MaterialDesignPaper}" /> |
138 | 139 | </Grid> |
139 | 140 | </Grid> |
|
160 | 161 | <RowDefinition Height="Auto"/> |
161 | 162 | </Grid.RowDefinitions> |
162 | 163 | <Rectangle Grid.Row="0" |
163 | | - Fill="{DynamicResource MaterialDesignPaper}" |
164 | | - Height="8"/> |
| 164 | + Fill="{DynamicResource MaterialDesignPaper}" |
| 165 | + Height="{StaticResource PopupTopBottomMargin}"/> |
165 | 166 |
|
166 | 167 | <ContentPresenter Grid.Row="1"/> |
167 | 168 |
|
168 | 169 | <Rectangle Grid.Row="2" |
169 | | - Height="8" |
| 170 | + Height="{StaticResource PopupTopBottomMargin}" |
170 | 171 | Fill="{DynamicResource MaterialDesignPaper}" /> |
171 | 172 | </Grid> |
172 | 173 | </Grid> |
|
0 commit comments