private static void AccessEditModePropertyChangedCallback(DependencyObject d, DependencyPropertyChangedEventArgs e) { ComponentAccessPicker instance = d as ComponentAccessPicker; if (instance == null) { return; } // re-display information instance.Children.Clear(); instance.PopulteGrid(); instance.SetUserMark(); }
private static object ComponentToDisplayCoerceValueCallback(DependencyObject d, object baseValue) { ComponentAccessPicker instance = d as ComponentAccessPicker; if (instance == null) { return(baseValue); } if (instance.ComponentToDisplay != null) { instance.ComponentToDisplay.PropertyChanged -= instance.ComponentToDisplay_PropertyChanged; } return(baseValue); }
private static void LoggedUserPropertyChangedCallback(DependencyObject d, DependencyPropertyChangedEventArgs e) { ComponentAccessPicker instance = d as ComponentAccessPicker; if (instance == null) { return; } if (instance.IsLoaded) { instance.SetUserMark(); } instance.AccessEditMode = (instance.LoggedUser == ComponentManagerType.ADMINISTRATOR); }
private static void ComponentToDisplayPropertyChangedCallback(DependencyObject d, DependencyPropertyChangedEventArgs e) { ComponentAccessPicker instance = d as ComponentAccessPicker; if (instance == null) { return; } // event handler, if the profile changes if (instance.ComponentToDisplay != null) { instance.ComponentToDisplay.PropertyChanged += instance.ComponentToDisplay_PropertyChanged; } // display information instance.access_adapted_to_slot_once = false; instance.AccessEditMode = (instance.LoggedUser == ComponentManagerType.ADMINISTRATOR); instance.Children.Clear(); instance.PopulteGrid(); instance.SetUserMark(); }