protected override async void Execute(object parameter) { if (parameter is StorageItemViewModel itemVM) { if (itemVM.Item is StorageItemImageSource storageItemImageSource) { var param = StorageItemViewModel.CreatePageParameter(itemVM); var tileArguments = new SecondaryTileArguments(); if (param.TryGetValue(PageNavigationConstants.Path, out string path)) { tileArguments.Path = Uri.UnescapeDataString(path); } if (param.TryGetValue(PageNavigationConstants.PageName, out string pageName)) { tileArguments.PageName = pageName; } var result = await _secondaryTileManager.AddSecondaryTile( tileArguments, itemVM.Name, storageItemImageSource.StorageItem ); } } }
public async Task <bool> AddSecondaryTile(SecondaryTileArguments arguments, string displayName, IStorageItem storageItem) {