Ejemplo n.º 1
0
        private static PhoneApplicationPageBackKeyPressCommandBehavior GetOrCreateBehavior(Microsoft.Phone.Controls.PhoneApplicationPage buttonBase)
        {
            PhoneApplicationPageBackKeyPressCommandBehavior behavior = buttonBase.GetValue(BackKeyPressCommandBehaviorProperty) as PhoneApplicationPageBackKeyPressCommandBehavior;

            if (behavior == null)
            {
                behavior = new PhoneApplicationPageBackKeyPressCommandBehavior(buttonBase);
                buttonBase.SetValue(BackKeyPressCommandBehaviorProperty, behavior);
            }

            return(behavior);
        }
Ejemplo n.º 2
0
 public static void SetCommandParameter(Microsoft.Phone.Controls.PhoneApplicationPage buttonBase, object parameter)
 {
     buttonBase.SetValue(CommandParameterProperty, parameter);
 }
Ejemplo n.º 3
0
 public static void SetCommand(Microsoft.Phone.Controls.PhoneApplicationPage buttonBase, ICommand command)
 {
     buttonBase.SetValue(CommandProperty, command);
 }
Ejemplo n.º 4
0
 public static void SetApplicationBar(Microsoft.Phone.Controls.PhoneApplicationPage obj, ApplicationBar value)
 {
     obj.SetValue(ApplicationBarProperty, value);
 }