summaryrefslogtreecommitdiff
path: root/python_client.py
diff options
context:
space:
mode:
authorTreeki <treeki@gmail.com>2014-01-25 07:22:54 +0100
committerTreeki <treeki@gmail.com>2014-01-25 07:22:54 +0100
commitcc847c2f7c8678c169a83c5b553d3d073ad869a4 (patch)
tree445d5f97c8fa9e11db8a0d5efbbc800d8d74eaa9 /python_client.py
parentd67fdae167bf5118b17d3bfaeb5f91929dfa812d (diff)
downloadbounce4-cc847c2f7c8678c169a83c5b553d3d073ad869a4.tar.gz
bounce4-cc847c2f7c8678c169a83c5b553d3d073ad869a4.zip
add query windows
Diffstat (limited to '')
-rw-r--r--python_client.py9
1 files changed, 8 insertions, 1 deletions
diff --git a/python_client.py b/python_client.py
index 4e7f1a3..5a82031 100644
--- a/python_client.py
+++ b/python_client.py
@@ -346,7 +346,7 @@ class MainWindow(QtWidgets.QMainWindow):
pos += msglen
msgs.append(msg)
- if wtype == 1:
+ if wtype == 1 or wtype == 3:
tab = WindowTab(self)
elif wtype == 2:
tab = ChannelTab(self)
@@ -363,6 +363,13 @@ class MainWindow(QtWidgets.QMainWindow):
wndID, msglen = struct.unpack_from('<II', pdata, 0)
msg = pdata[8:8+msglen].decode('utf-8', 'replace')
self.tabLookup[wndID].pushMessage(msg)
+ elif ptype == 0x103:
+ # WINDOW RENAME
+ wndID, msglen = struct.unpack_from('<II', pdata, 0)
+ title = pdata[8:8+msglen].decode('utf-8', 'replace')
+
+ tabObj = self.tabLookup[wndID]
+ self.tabs.setTabText(self.tabs.indexOf(tabObj), title)
elif ptype == 0x120:
# Add users to channel