设置OpenFaint自定义开始选项卡(iPhone应用程序)
我目前正在为iPhone应用程序设置OpenFeint。默认情况下,加载的第一个选项卡是“Friends”(选项卡视图列表中的第三个选项卡),但我想对其进行自定义,以加载应用程序的主选项卡(列表中的第一个选项卡)设置OpenFaint自定义开始选项卡(iPhone应用程序),iphone,objective-c,openfeint,Iphone,Objective C,Openfeint,我目前正在为iPhone应用程序设置OpenFeint。默认情况下,加载的第一个选项卡是“Friends”(选项卡视图列表中的第三个选项卡),但我想对其进行自定义,以加载应用程序的主选项卡(列表中的第一个选项卡) 有人知道如何做到这一点吗?任何帮助都将不胜感激 遵循所有启动逻辑后,我终于在OpenFeint+Private.mm中找到了这个函数: + (void)presentRootControllerWithTabbedDashboard { UITabBarController*
有人知道如何做到这一点吗?任何帮助都将不胜感激 遵循所有启动逻辑后,我终于在OpenFeint+Private.mm中找到了这个函数:
+ (void)presentRootControllerWithTabbedDashboard
{
UITabBarController* tabController = (UITabBarController*)OFControllerLoader::load(@"TabbedDashboard");
if (![OpenFeint lastLoggedInUserHadFriendsOnBootup])
{
tabController.selectedIndex = 2;
}
[OpenFeint presentRootControllerWithModal:tabController];
}
正如预期的那样,将.selectedIndex更改为0非常有效