@@ -223,6 +223,43 @@ public static void SetMouseOverBorderBrush(DependencyObject obj, Brush value)
223
223
obj . SetValue ( MouseOverBorderBrushProperty , value ) ;
224
224
}
225
225
226
+ public static readonly DependencyProperty DisabledBorderBrushProperty
227
+ = DependencyProperty . RegisterAttached (
228
+ "DisabledBorderBrush" ,
229
+ typeof ( Brush ) ,
230
+ typeof ( ControlsHelper ) ,
231
+ new FrameworkPropertyMetadata ( Brushes . Transparent , FrameworkPropertyMetadataOptions . AffectsRender | FrameworkPropertyMetadataOptions . Inherits ) ) ;
232
+
233
+ /// <summary>
234
+ /// Gets the brush used to draw the disabled border brush.
235
+ /// </summary>
236
+ [ Category ( AppName . MahApps ) ]
237
+ [ AttachedPropertyBrowsableForType ( typeof ( TextBox ) ) ]
238
+ [ AttachedPropertyBrowsableForType ( typeof ( CheckBox ) ) ]
239
+ [ AttachedPropertyBrowsableForType ( typeof ( RadioButton ) ) ]
240
+ [ AttachedPropertyBrowsableForType ( typeof ( DatePicker ) ) ]
241
+ [ AttachedPropertyBrowsableForType ( typeof ( ComboBox ) ) ]
242
+ [ AttachedPropertyBrowsableForType ( typeof ( Tile ) ) ]
243
+ public static Brush GetDisabledBorderBrush ( DependencyObject obj )
244
+ {
245
+ return ( Brush ) obj . GetValue ( DisabledBorderBrushProperty ) ;
246
+ }
247
+
248
+ /// <summary>
249
+ /// Sets the brush used to draw the disabled border brush.
250
+ /// </summary>
251
+ [ Category ( AppName . MahApps ) ]
252
+ [ AttachedPropertyBrowsableForType ( typeof ( TextBox ) ) ]
253
+ [ AttachedPropertyBrowsableForType ( typeof ( CheckBox ) ) ]
254
+ [ AttachedPropertyBrowsableForType ( typeof ( RadioButton ) ) ]
255
+ [ AttachedPropertyBrowsableForType ( typeof ( DatePicker ) ) ]
256
+ [ AttachedPropertyBrowsableForType ( typeof ( ComboBox ) ) ]
257
+ [ AttachedPropertyBrowsableForType ( typeof ( Tile ) ) ]
258
+ public static void SetDisabledBorderBrush ( DependencyObject obj , Brush value )
259
+ {
260
+ obj . SetValue ( DisabledBorderBrushProperty , value ) ;
261
+ }
262
+
226
263
/// <summary>
227
264
/// DependencyProperty for <see cref="CornerRadius" /> property.
228
265
/// </summary>
0 commit comments