diff --git a/Src/Network.cpp b/Src/Network.cpp index 2c89a23..cfe2419 100644 --- a/Src/Network.cpp +++ b/Src/Network.cpp @@ -1241,7 +1241,7 @@ bool Network::ConnectToPeer() void Network::Disconnect() { - printf("Disconnecting\n"); + Gui::gui->status_bar->queueMessage("Disconnecting"); this->ResetNetworkUpdate(); NetworkUpdate *disconnect = InitNetworkUpdate(this->cur_ud, DISCONNECT, diff --git a/Src/gui/network_menu.cpp b/Src/gui/network_menu.cpp index 3594a0f..bc0a223 100644 --- a/Src/gui/network_menu.cpp +++ b/Src/gui/network_menu.cpp @@ -69,7 +69,9 @@ public: Gui::gui->pushView(Gui::gui->nrv); break; case 4: - if ( strncmp(Gui::gui->np->NetworkName, "Unset", strlen("Unset")) == 0) + if (TheC64->network) + TheC64->network->Disconnect(); + else if ( strncmp(Gui::gui->np->NetworkName, "Unset", strlen("Unset")) == 0) Gui::gui->pushDialogueBox(new DialogueBox(network_unset_name_dlg)); else { @@ -130,7 +132,7 @@ private: this->messages[2] = this->strs[2]; this->messages[3] = " "; - this->messages[4] = "Connect to the network!"; + this->messages[4] = TheC64->network ? "Disconnect" : "Connect to the network!"; this->messages[5] = " "; this->messages[6] = "Post network message"; this->messages[7] = "Post peer message";