Beispiel #1
0
        private static GridItemsSourceChangedBehavior GetOrCreateBehavior(GridDataControl control)
        {
            GridItemsSourceChangedBehavior behavior =
                control.GetValue(GridItemsSourceChangedBehaviorProperty) as GridItemsSourceChangedBehavior;

            if (behavior == null)
            {
                behavior = new GridItemsSourceChangedBehavior(control);
                control.SetValue(GridItemsSourceChangedBehaviorProperty, behavior);
            }
            return(behavior);
        }
Beispiel #2
0
        private static GridQueryCellStyleInfoBehavior GetOrCreateBehavior(GridDataControl control)
        {
            GridQueryCellStyleInfoBehavior behavior =
                control.GetValue(GridQueryCellStyleInfoBehaviorProperty) as GridQueryCellStyleInfoBehavior;

            if (behavior == null)
            {
                behavior = new GridQueryCellStyleInfoBehavior(control);
                control.SetValue(GridQueryCellStyleInfoBehaviorProperty, behavior);
            }
            return(behavior);
        }
Beispiel #3
0
 public static object GetCommandParameter(GridDataControl control)
 {
     return(control.GetValue(CommandParameterProperty));
 }
Beispiel #4
0
 public static ICommand GetCommand(GridDataControl control)
 {
     return(control.GetValue(CommandProperty) as ICommand);
 }