Fix connect button not enabling

Apparently this had never been staged, and while everyone was having
problems with the connect button, everything was working just fine for
me.

This enables the connect button a bit earlier in the handshake process
than in 2.6, since there are some older servers out there that don't
send FL (and so the connect button would never get enabled). This might
lead to race conditions, and sometimes the progress bar does hang,
but you can just cancel and reconnect - I haven't encountered a crash
so far.
This commit is contained in:
oldmud0 2020-06-12 16:45:50 -05:00
parent 0bdcf03793
commit 3d3de26140

View File

@ -157,6 +157,9 @@ void AOApplication::server_packet_received(AOPacket *p_packet)
s_pv = f_contents.at(0).toInt(); s_pv = f_contents.at(0).toInt();
server_software = f_contents.at(1); server_software = f_contents.at(1);
if (lobby_constructed)
w_lobby->enable_connect_button();
send_server_packet(new AOPacket("ID#AO2#" + get_version_string() + "#%")); send_server_packet(new AOPacket("ID#AO2#" + get_version_string() + "#%"));
} }
else if (header == "CT") { else if (header == "CT") {