static CommandMenuItem() { CommandProperty.AddOwner(typeof(CommandMenuItem), new FrameworkPropertyMetadata(OnCommandChanged)); HeaderProperty.AddOwner(typeof(CommandMenuItem), new FrameworkPropertyMetadata(null, CoerceHeader)); SourceProperty.AddOwner(typeof(CommandMenuItem), new FrameworkPropertyMetadata(null, CoerceSource)); InputGestureTextProperty.AddOwner(typeof(CommandMenuItem), new FrameworkPropertyMetadata(null, CoerceInputGestureText)); }
static CommandButton() { CommandProperty.AddOwner(typeof(CommandButton), new FrameworkPropertyMetadata(OnCommandChanged)); //ContentProperty.AddOwner(typeof(CommandButton), // new FrameworkPropertyMetadata(null, CoerceContent)); SourceProperty.AddOwner(typeof(CommandButton), new FrameworkPropertyMetadata(null, CoerceSource)); ToolTipProperty.AddOwner(typeof(CommandButton), new FrameworkPropertyMetadata(null, CoerceToolTip)); }