Пример #1
0
 public static async Task ReloadSimulatorAsync(StorageFile storageFile)
 {
     using (var stream = await storageFile.OpenStreamForReadAsync().ConfigureAwait(false))
     {
         var document = XDocument.Load(stream);
         _instance = FromXml(document);
     }
 }
Пример #2
0
        public static async Task <string> RequestAppPurchaseAsync(bool includeReceipt)
        {
#if DEBUG
            return(await CurrentAppSimulator.RequestAppPurchaseAsync(includeReceipt));
#else
            return(await CurrentApp.RequestAppPurchaseAsync(includeReceipt));
#endif
        }
Пример #3
0
        /// <summary>
        /// Loads the app's listing information asynchronously.
        /// </summary>
        /// <returns></returns>
        public static async Task <ListingInformation> LoadListingInformationAsync()
        {
#if DEBUG
            return(ListingInformation.Create(await CurrentAppSimulator.LoadListingInformationAsync()));
#else
            return(ListingInformation.Create(await CurrentApp.LoadListingInformationAsync()));
#endif
        }
Пример #4
0
        public static async Task <string> GetProductReceiptAsync(string productId)
        {
#if DEBUG
            return(await CurrentAppSimulator.GetProductReceiptAsync(productId));
#else
            return(await CurrentApp.GetProductReceiptAsync(productId));
#endif
        }
Пример #5
0
        public static async Task <string> GetAppReceiptAsync()
        {
#if DEBUG
            return(await CurrentAppSimulator.GetAppReceiptAsync());
#else
            return(await CurrentApp.GetAppReceiptAsync());
#endif
        }
Пример #6
0
 /// <summary>
 /// Reloads and restarts the simulator when provided with a new StorageFile reference
 /// </summary>
 /// <param name="storageFile">A new WinStoreAppProxy.xml file with the desired settings</param>
 public static async Task ReloadSimulatorSettingsAsync(StorageFile storageFile)
 {
     await CurrentAppSimulator.ReloadSimulatorAsync(storageFile);
 }