简体   繁体   English

AppDelegate setFullscreen:无法识别的选择器发送到实例

[英]AppDelegate setFullscreen: unrecognized selector sent to instance

I am trying to receive RevMobAdsDelegate events in my AppDelegate and they are being called with following runtime signal errors . 我正在尝试在我的AppDelegate中接收RevMobAdsDelegate事件,并且正在使用以下运行时信号错误来调用它们。

[3496:207] [RevMob myapplication App]
SetChartBoostRequestFlag - StopLoadingWait
[3496:207] [RevMob myapplication App] StopLoadingWait routine
[3496:207] [RevMob] Starting RevMobAds
[3496:207] [RevMob] Initializing Fullscreen.
[3496:207] -[AppDelegate setFullscreen:]: unrecognized selector sent to instance    0xa20b4e0
(gdb) 

i have already added RevModAds Framework in my code still it's giving me this kind of signal error. 我已经在我的代码中添加了RevModAds Framework,仍然给了我这种信号错误。 and application crashed after loading starting banner. 加载开始横幅后,应用程序崩溃了。

i have installed RevMobads sdk from here http://sdk.revmob.com/ios.html#fullscreen 我已经从此处http://sdk.revmob.com/ios.html#fullscreen安装了RevMobads sdk

Do you have a setFullscreen: method in your AppDelegate? 您的AppDelegate中是否有setFullscreen:方法? If not, you better implement it. 如果没有,您最好实施它。 The documentation says that there is a showFullscreen , which is different. 该文档说有一个showFullscreen ,这是不同的。

You can do something like this: 您可以执行以下操作:

  #define REVMOB_APP_ID @"50cd7e844ae728120000003f"

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 
  {  
            [RevMobAds startSessionWithAppID:REVMOB_APP_ID];
            [self showAds];
            ..
            ..
  }

  -(void)showAds  //call this from game over, game pause
  {
            [[RevMobAds session] showFullscreen];
  }

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM