Added title bar and basic message and command input
This commit is contained in:
parent
508a04cf4c
commit
f42d6011c6
23 changed files with 399 additions and 83 deletions
|
@ -48,6 +48,7 @@ func handleWS(ws *websocket.Conn) {
|
|||
channels := session.user.GetChannels()
|
||||
for i, channel := range channels {
|
||||
channels[i].Users = channelStore.GetUsers(channel.Server, channel.Name)
|
||||
channels[i].Topic = channelStore.GetTopic(channel.Server, channel.Name)
|
||||
}
|
||||
|
||||
session.sendJSON("channels", channels)
|
||||
|
@ -106,6 +107,17 @@ func handleWS(ws *websocket.Conn) {
|
|||
irc.Part(data.Channels...)
|
||||
}
|
||||
|
||||
case "quit":
|
||||
var data Quit
|
||||
|
||||
json.Unmarshal(req.Request, &data)
|
||||
|
||||
if irc, ok := session.getIRC(data.Server); ok {
|
||||
channelStore.RemoveUserAll(irc.nick, data.Server)
|
||||
session.user.RemoveServer(data.Server)
|
||||
irc.Quit()
|
||||
}
|
||||
|
||||
case "chat":
|
||||
var data Chat
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue