Hello i am using Urban AirShip Rich Push Notification for IOS in cocos2d. I am getting the inbox for the Rich Notification but i am getting it in potrait mode. I want to get the inbox in the landscape mode.
Here is the code i am using
[UAInbox useCustomUI:[UAInboxUI class]];//sample UI implementation
[UAInbox shared].pushHandler.delegate = [UAInboxUI shared];
// If the application gets an UAInbox message id on launch open it up immediately.
// Only works for the default inbox
[UAInboxUI shared].inboxParentController=window_.rootViewController;
[UAInboxPushHandler handleLaunchOptions:launchOptions];
if ([[UAInbox shared].pushHandler hasLaunchMessage]) {
[[[UAInbox shared] uiClass] loadLaunchMessage];
}
// Create the main window
window_ = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
[UAInbox displayInbox:window_.rootViewController animated:YES];
Any help would be greatly appreciated. Thanks in Advance
Ok Solved this problem by myself. Urban Airship already has build up capability to show in landscape mode.
Always write methods to display UAInbox in the AppDelegate.mm(in my case i needed to show the inbox in the boot up) in the viewdidfinishwithlaunchingoptions
Also if you want to add UrbanAirship inbox on button click(from a cocos2d scene) then for it to display properly always add it to the rootViewController of your cocos2d game in my case in
window_.rootViewControllerinstead of showing UrbanAirship in the scene by adding it to uiviewcontroller and showing the uiviewcontroller to the cocos2d scene usingthe [[CCDirector SharedDirector]view]addsubview:uiviewcontroller].