diff options
Diffstat (limited to 'bouncer/mobileclient.cpp')
-rw-r--r-- | bouncer/mobileclient.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/bouncer/mobileclient.cpp b/bouncer/mobileclient.cpp index fb8b3c1..65ddefe 100644 --- a/bouncer/mobileclient.cpp +++ b/bouncer/mobileclient.cpp @@ -41,6 +41,16 @@ void MobileClient::packetReceivedEvent(Packet::Type type, Buffer &pkt) { window->handleUserInput(text); + } else if (type == Packet::C2B_WINDOW_CLOSE) { + int winID = pkt.readU32(); + Window *window = bouncer->findWindow(winID); + if (!window) { + printf("[MobileClient:%p] Close request for unknown window %d\n", this, winID); + return; + } + + window->handleUserClosed(); + } else { printf("[MobileClient:%p] Unrecognised packet for MobileClient: type %d, size %d\n", this, type, pkt.size()); |