Caliburn.Micro.Action.SetTarget C# (CSharp) Метод

SetTarget() публичный статический Метод

Sets the target of the ActionMessage .
public static SetTarget ( global::Xamarin.Forms.BindableObject d, object target ) : void
d global::Xamarin.Forms.BindableObject The element to attach the target to.
target object The target for instances of .
Результат void
        public static void SetTarget(DependencyObject d, object target) {
            d.SetValue(TargetProperty, target);
        }

Usage Example

Пример #1
0
        static void ItemsSourceChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            var pager  = (Pager)d;
            var source = (IBindablePagedQuery)e.NewValue;

            source.IsLoadingChanged += (s, args) =>
            {
                var state = args.Value ? "Loading" : "Loaded";
                Execute.OnUIThread(() => VisualStateManager.GoToState(pager, state, true));
            };
            Action.SetTarget(pager.LayoutRoot, e.NewValue);
        }
All Usage Examples Of Caliburn.Micro.Action::SetTarget