public StickerBoardViewModel() { Name = "NEW BOARD"; Stickers = new SimpleCollection <StickerViewModel>(); Stickers.ParentViewModel = this; Commands = new SimpleCollection <CommandViewModel>(); var addCmd = new CommandViewModel(); addCmd.Command = Stickers.AddCommand; addCmd.CommandParameter = null; addCmd.Text = "Add Sticker"; addCmd.Image = new BitmapImage(new Uri("pack://application:,,,/StickerPlugin;component/Icons/add.png")); Commands.Add(addCmd); }
public MainViewModel() { DataTemplateSelector = new StickerPluginDataTemplateSelector(); StickerBoards = new SimpleSelectedCollection <StickerBoardViewModel>(); StickerBoards.ParentViewModel = this; Commands = new SimpleCollection <CommandViewModel>(); var addCmd = new CommandViewModel(); addCmd.Command = StickerBoards.AddCommand; addCmd.CommandParameter = null; addCmd.Text = ""; addCmd.Image = new BitmapImage(new Uri("pack://application:,,,/StickerPlugin;component/Icons/add.png")); Commands.Add(addCmd); }