stop local server if tab is closed

This commit is contained in:
Zlatin Balevsky
2019-11-18 09:06:29 +00:00
parent 9373d58b53
commit ff7c4eae28

View File

@@ -80,7 +80,10 @@ class ChatServerView {
}
def closeTab = {
if (model.buttonText == "Disconnect")
if (model.host == model.core.me) {
mvcGroup.parentGroup.controller.stopChatServer()
}
else if (model.buttonText == "Disconnect")
controller.disconnect()
int index = parent.indexOfComponent(pane)
parent.removeTabAt(index)