public static void SetPlacements(UIElement adorner, AdornerPlacementCollection value) { if (adorner == null) { throw new ArgumentNullException("adorner"); } adorner.SetValue(AdornerPanel.PlacementsProperty, (object)value); }
internal static AdornerPlacementCollection GetCurrentPlacements(UIElement adorner) { AdornerPlacementCollection placements = AdornerPanel.GetPlacements(adorner); if (placements == null || placements.Count == 0) { return((AdornerPlacementCollection)AdornerPanel.GetSyntaticSugarPlacements((DependencyObject)adorner)); } return(placements); }