summaryrefslogtreecommitdiff
path: root/cmd/irc/main.go
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--cmd/irc/main.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/cmd/irc/main.go b/cmd/irc/main.go
index 02f0304..b4461a5 100644
--- a/cmd/irc/main.go
+++ b/cmd/irc/main.go
@@ -76,10 +76,20 @@ func handleIRCEvent(app *ui.UI, ev irc.Event) {
case irc.UserPartEvent:
line := fmt.Sprintf("\x034-\x0314%s", ev.Nick)
app.AddLine(ev.Channel, line, ev.Time, true)
+ case irc.QueryMessageEvent:
+ line := formatIRCMessage(ev.Nick, ev.Content)
+ app.AddLine("home", line, ev.Time, false)
+ app.TypingStop("home", ev.Nick)
case irc.ChannelMessageEvent:
line := formatIRCMessage(ev.Nick, ev.Content)
app.AddLine(ev.Channel, line, ev.Time, false)
app.TypingStop(ev.Channel, ev.Nick)
+ case irc.QueryTypingEvent:
+ if ev.State == 1 || ev.State == 2 {
+ app.TypingStart("home", ev.Nick)
+ } else {
+ app.TypingStop("home", ev.Nick)
+ }
case irc.ChannelTypingEvent:
if ev.State == 1 || ev.State == 2 {
app.TypingStart(ev.Channel, ev.Nick)