mirror of
https://github.com/GabsPuNs/Project-Zenith-Main.git
synced 2026-05-31 23:24:39 +00:00
Some cleanup
Just a bit. i dont want to clean all the ifdef for consoles right now
This commit is contained in:
@@ -88,9 +88,6 @@ void UIScene_InGameInfoMenu::updateTooltips()
|
||||
}
|
||||
|
||||
if(g_NetworkManager.IsLocalGame()) keyX = -1;
|
||||
#ifdef __PSVITA__
|
||||
if(CGameNetworkManager::usingAdhocMode()) keyX = -1;
|
||||
#endif
|
||||
|
||||
INetworkPlayer *selectedPlayer = g_NetworkManager.GetPlayerBySmallId(m_players[m_playerList.getCurrentSelection()]->m_smallId);
|
||||
|
||||
@@ -250,33 +247,6 @@ void UIScene_InGameInfoMenu::handleInput(int iPad, int key, bool repeat, bool pr
|
||||
}
|
||||
break;
|
||||
case ACTION_MENU_Y:
|
||||
#if defined(__PS3__) || defined(__ORBIS__)
|
||||
if(pressed && iPad == ProfileManager.GetPrimaryPad())
|
||||
{
|
||||
#ifdef __PS3__
|
||||
// are we offline?
|
||||
if(!ProfileManager.IsSignedInLive(iPad))
|
||||
{
|
||||
// get them to sign in to online
|
||||
UINT uiIDA[2];
|
||||
uiIDA[0]=IDS_PRO_NOTONLINE_ACCEPT;
|
||||
uiIDA[1]=IDS_PRO_NOTONLINE_DECLINE;
|
||||
ui.RequestErrorMessage(IDS_PRO_NOTONLINE_TITLE, IDS_PRO_NOTONLINE_TEXT, uiIDA, 2, ProfileManager.GetPrimaryPad(),&UIScene_InGameInfoMenu::MustSignInReturnedPSN,this);
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
#ifdef __ORBIS__
|
||||
SQRNetworkManager_Orbis::RecvInviteGUI();
|
||||
#else // __PS3__
|
||||
int ret = sceNpBasicRecvMessageCustom(SCE_NP_BASIC_MESSAGE_MAIN_TYPE_INVITE, SCE_NP_BASIC_RECV_MESSAGE_OPTIONS_INCLUDE_BOOTABLE, SYS_MEMORY_CONTAINER_ID_INVALID);
|
||||
app.DebugPrintf("sceNpBasicRecvMessageCustom return %d ( %08x )\n", ret, ret);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
#else
|
||||
|
||||
|
||||
if(pressed && m_playerList.hasFocus() && (m_playerList.getItemCount() > 0) && (m_playerList.getCurrentSelection() < m_players.size()) )
|
||||
{
|
||||
INetworkPlayer *player = g_NetworkManager.GetPlayerBySmallId(m_players[m_playerList.getCurrentSelection()]->m_smallId);
|
||||
@@ -284,30 +254,13 @@ void UIScene_InGameInfoMenu::handleInput(int iPad, int key, bool repeat, bool pr
|
||||
{
|
||||
PlayerUID uid = player->GetUID();
|
||||
if( uid != INVALID_XUID )
|
||||
{
|
||||
#ifdef __PSVITA__
|
||||
PSVITA_STUBBED;
|
||||
#else
|
||||
ProfileManager.ShowProfileCard(iPad,uid);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
break;
|
||||
case ACTION_MENU_X:
|
||||
|
||||
if(pressed && !repeat && !g_NetworkManager.IsLocalGame() )
|
||||
{
|
||||
#ifdef __PSVITA__
|
||||
if(CGameNetworkManager::usingAdhocMode() == false)
|
||||
g_NetworkManager.SendInviteGUI(iPad);
|
||||
#else
|
||||
g_NetworkManager.SendInviteGUI(iPad);
|
||||
#endif
|
||||
}
|
||||
|
||||
break;
|
||||
case ACTION_MENU_OK:
|
||||
#ifdef __ORBIS__
|
||||
@@ -494,42 +447,4 @@ UIScene_InGameInfoMenu::PlayerInfo *UIScene_InGameInfoMenu::BuildPlayerInfo(INet
|
||||
info->m_name = playerName;
|
||||
|
||||
return info;
|
||||
}
|
||||
|
||||
#if defined __PS3__ || defined __PSVITA__
|
||||
int UIScene_InGameInfoMenu::MustSignInReturnedPSN(void *pParam,int iPad,C4JStorage::EMessageResult result)
|
||||
{
|
||||
UIScene_InGameInfoMenu* pClass = (UIScene_InGameInfoMenu*)pParam;
|
||||
|
||||
if(result==C4JStorage::EMessage_ResultAccept)
|
||||
{
|
||||
#ifdef __PS3__
|
||||
SQRNetworkManager_PS3::AttemptPSNSignIn(&UIScene_InGameInfoMenu::ViewInvites_SignInReturned, pClass);
|
||||
#else // __PSVITA__
|
||||
SQRNetworkManager_Vita::AttemptPSNSignIn(&UIScene_InGameInfoMenu::ViewInvites_SignInReturned, pClass);
|
||||
#endif
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int UIScene_InGameInfoMenu::ViewInvites_SignInReturned(void *pParam,bool bContinue, int iPad)
|
||||
{
|
||||
if(bContinue==true)
|
||||
{
|
||||
// Check if we're signed in to LIVE
|
||||
if(ProfileManager.IsSignedInLive(iPad))
|
||||
{
|
||||
#ifdef __ORBIS__
|
||||
SQRNetworkManager_Orbis::RecvInviteGUI();
|
||||
#elif defined(__PS3__)
|
||||
int ret = sceNpBasicRecvMessageCustom(SCE_NP_BASIC_MESSAGE_MAIN_TYPE_INVITE, SCE_NP_BASIC_RECV_MESSAGE_OPTIONS_INCLUDE_BOOTABLE, SYS_MEMORY_CONTAINER_ID_INVALID);
|
||||
app.DebugPrintf("sceNpBasicRecvMessageCustom return %d ( %08x )\n", ret, ret);
|
||||
#else // __PSVITA__
|
||||
SQRNetworkManager_Vita::RecvInviteGUI();
|
||||
#endif
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
}
|
||||
Reference in New Issue
Block a user