private static void RewardedAdDidOpenCallback(IntPtr rewardedAdClient) { RewardedAdClient client = IntPtrToRewardedAdClient(rewardedAdClient); if (client.OnAdOpening != null) { client.OnAdOpening(client, EventArgs.Empty); } }
private static void RewardedAdDidReceiveAdCallback(IntPtr rewardedAdClient) { RewardedAdClient client = IntPtrToRewardedAdClient(rewardedAdClient); if (client.OnAdLoaded != null) { client.OnAdLoaded(client, EventArgs.Empty); } }
private static void AdDidRecordImpressionCallback(IntPtr rewardedAdClient) { RewardedAdClient client = IntPtrToRewardedAdClient(rewardedAdClient); if (client.OnAdDidRecordImpression != null) { client.OnAdDidRecordImpression(client, EventArgs.Empty); } }
private static void AdDidDismissFullScreenContentCallback(IntPtr rewardedAdClient) { RewardedAdClient client = IntPtrToRewardedAdClient(rewardedAdClient); if (client.OnAdDidDismissFullScreenContent != null) { client.OnAdDidDismissFullScreenContent(client, EventArgs.Empty); } }
private static void AdFailedToPresentFullScreenContentCallback(IntPtr rewardedAdClient, IntPtr error) { RewardedAdClient client = IntPtrToRewardedAdClient(rewardedAdClient); if (client.OnAdFailedToPresentFullScreenContent != null) { AdErrorClientEventArgs args = new AdErrorClientEventArgs() { AdErrorClient = new AdErrorClient(error) }; client.OnAdFailedToPresentFullScreenContent(client, args); } }
private static void RewardedAdDidFailToShowAdWithErrorCallback( IntPtr rewardedAdClient, string error) { RewardedAdClient client = IntPtrToRewardedAdClient(rewardedAdClient); if (client.OnAdFailedToShow != null) { AdErrorEventArgs args = new AdErrorEventArgs() { Message = error }; client.OnAdFailedToShow(client, args); } }
private static void RewardedAdDidFailToReceiveAdWithErrorCallback( IntPtr rewardedAdClient, IntPtr error) { RewardedAdClient client = IntPtrToRewardedAdClient(rewardedAdClient); if (client.OnAdFailedToLoad != null) { LoadAdErrorClientEventArgs args = new LoadAdErrorClientEventArgs() { LoadAdErrorClient = new LoadAdErrorClient(error) }; client.OnAdFailedToLoad(client, args); } }
private static void RewardedAdDidFailToShowAdWithErrorCallback( IntPtr rewardedAdClient, IntPtr error) { RewardedAdClient client = IntPtrToRewardedAdClient(rewardedAdClient); if (client.OnAdFailedToShow != null) { AdErrorClientEventArgs args = new AdErrorClientEventArgs() { AdErrorClient = new AdErrorClient(error), Message = Externs.GADUGetAdErrorMessage(error) }; client.OnAdFailedToShow(client, args); } }
private static void RewardedAdUserDidEarnRewardCallback( IntPtr rewardedAdClient, string rewardType, double rewardAmount) { RewardedAdClient client = IntPtrToRewardedAdClient( rewardedAdClient); if (client.OnUserEarnedReward != null) { Reward args = new Reward() { Type = rewardType, Amount = rewardAmount }; client.OnUserEarnedReward(client, args); } }
private static void RewardedAdPaidEventCallback( IntPtr rewardedAdClient, int precision, long value, string currencyCode) { RewardedAdClient client = IntPtrToRewardedAdClient(rewardedAdClient); if (client.OnPaidEvent != null) { AdValue adValue = new AdValue() { Precision = (AdValue.PrecisionType)precision, Value = value, CurrencyCode = currencyCode }; AdValueEventArgs args = new AdValueEventArgs() { AdValue = adValue }; client.OnPaidEvent(client, args); } }