overlays/rpcn: Create list even if rpcn connection failed

This commit is contained in:
Megamouse 2025-03-25 17:31:57 +01:00
parent c52920755a
commit 6fed8338e2

View file

@ -453,6 +453,7 @@ namespace rsx
std::vector<std::unique_ptr<overlay_element>> entries;
std::string selected_user;
s32 selected_index = 0;
bool rpcn_connected = true;
// Get selected user name
if (m_list && m_current_page == m_last_page)
@ -516,20 +517,25 @@ namespace rsx
{
rsx_log.error("Failed to connect to RPCN: %s", rpcn::rpcn_state_to_string(res));
status_flags |= status_bits::invalidate_image_cache;
m_list.reset();
return;
rpcn_connected = false;
}
if (auto res = m_rpcn->wait_for_authentified(); res != rpcn::rpcn_state::failure_no_failure)
{
rsx_log.error("Failed to authentify to RPCN: %s", rpcn::rpcn_state_to_string(res));
status_flags |= status_bits::invalidate_image_cache;
m_list.reset();
return;
rpcn_connected = false;
}
// Get friends, setup callback and setup comboboxes
m_rpcn->get_friends(m_friend_data);
// Get friends
if (rpcn_connected)
{
m_rpcn->get_friends(m_friend_data);
}
else
{
m_friend_data = {};
}
switch (m_current_page)
{