Esempio 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);
        }
Esempio n. 2
0
 public static void SetCommandParameter(Microsoft.Phone.Controls.PhoneApplicationPage buttonBase, object parameter)
 {
     buttonBase.SetValue(CommandParameterProperty, parameter);
 }
Esempio n. 3
0
 public static void SetCommand(Microsoft.Phone.Controls.PhoneApplicationPage buttonBase, ICommand command)
 {
     buttonBase.SetValue(CommandProperty, command);
 }
 public static void SetApplicationBar(Microsoft.Phone.Controls.PhoneApplicationPage obj, ApplicationBar value)
 {
     obj.SetValue(ApplicationBarProperty, value);
 }