This repository has been archived on 2024-07-28. You can view files and clone it, but cannot push or open issues or pull requests.
cairde/message.go

71 lines
1.6 KiB
Go

package main
import (
"cwtch.im/cwtch/app"
"git.openprivacy.ca/openprivacy/connectivity"
)
// ---------------------------------------------------------------------------
// ACN messages
// ---------------------------------------------------------------------------
type turnAcnOnMsg struct{}
type acnOnMsg struct {
app app.Application
acn connectivity.ACN
}
type turnAcnOffMsg struct {
quitProgram bool
}
type acnOffMsg struct {
quitProgram bool
}
type acnAlreadyOnlineMsg struct{}
type acnOfflineMsg struct{}
type acnConnectingMsg struct{}
type acnErrMsg struct {
err error
}
func (e acnErrMsg) Error() string {
return e.err.Error()
}
// ---------------------------------------------------------------------------
// help messages
// ---------------------------------------------------------------------------
type showGettingStartedGuideMsg struct{}
// ---------------------------------------------------------------------------
// profile messages
// ---------------------------------------------------------------------------
type profileInfoMsg struct{}
type startProfileQueuePollMsg struct{ onion string }
type createProfileMsg struct {
name string
password string
}
type profileUnlockMsg struct {
password string
}
// ---------------------------------------------------------------------------
// TODO: categorize messages below
// ---------------------------------------------------------------------------
type sendStatusMsg struct{ lines []string }
type renderStatusMsg struct{ line string }
type cmdMsg struct{ output []string }
type clearScreenMsg struct{}