Skip to content
This repository was archived by the owner on May 1, 2024. It is now read-only.

add AppEventDelegate to the public delegates and events #510

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 10 additions & 4 deletions source/Google/MobileAds/ApiDefinition.cs
Original file line number Diff line number Diff line change
Expand Up @@ -178,8 +178,8 @@ interface AdReward {

[BaseType (typeof (UIView),
Name = "GADBannerView",
Delegates = new string [] { "Delegate", "AdSizeDelegate" },
Events = new Type [] { typeof (BannerViewDelegate), typeof (AdSizeDelegate) })]
Delegates = new string [] { "Delegate", "AdSizeDelegate", "AppEventDelegate" },
Events = new Type [] { typeof (BannerViewDelegate), typeof (AdSizeDelegate), typeof(AppEventDelegate) })]
interface BannerView {

[Export ("initWithFrame:")]
Expand Down Expand Up @@ -211,6 +211,10 @@ interface BannerView {
[Export ("delegate", ArgumentSemantic.Weak)]
IBannerViewDelegate Delegate { get; set; }

[NullAllowed]
[Export ("appEventDelegate", ArgumentSemantic.Weak)]
IAppEventDelegate AppEventDelegate { get; set; }

[Obsolete]
[NullAllowed]
[Export ("inAppPurchaseDelegate", ArgumentSemantic.Weak)]
Expand Down Expand Up @@ -899,9 +903,11 @@ interface IAppEventDelegate {
[Protocol]
[BaseType (typeof (NSObject), Name = "GADAppEventDelegate")]
interface AppEventDelegate {
[EventArgs ("AppEventDidReceiveAppEvent")]
[Export ("adView:didReceiveAppEvent:withInfo:")]
void AdViewDidReceiveAppEvent (BannerView banner, string name, [NullAllowed] string info);

[EventArgs ("AppEventDidReceiveAppEvent")]
[Export ("interstitial:didReceiveAppEvent:withInfo:")]
void InterstitialDidReceiveAppEvent (Interstitial interstitial, string name, [NullAllowed] string info);
}
Expand Down Expand Up @@ -2582,8 +2588,8 @@ interface BannerAdLoaderDelegate : Google.MobileAds.AdLoaderDelegate {

[BaseType (typeof (Google.MobileAds.BannerView),
Name = "DFPBannerView",
Delegates = new string [] { "AdSizeDelegate" },
Events = new Type [] { typeof (Google.MobileAds.AdSizeDelegate) })]
Delegates = new string [] { "AdSizeDelegate", "AppEventDelegate" },
Events = new Type [] { typeof (Google.MobileAds.AdSizeDelegate), typeof(Google.MobileAds.AppEventDelegate) })]
interface BannerView {

[Export ("initWithFrame:")]
Expand Down