uiconfig: use pointer references to uiConfig

This patch changes references to uiConfig in function signatures and
structs to be pointers.

Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
Acked-by: Robin Jarry <robin@jarry.cc>
This commit is contained in:
Tim Culverhouse 2022-07-03 10:11:12 -05:00 committed by Robin Jarry
parent 12e8217d1f
commit d45c07eb6a
15 changed files with 48 additions and 48 deletions
widgets

View file

@ -284,7 +284,7 @@ func (c *Composer) Encrypt() bool {
func (c *Composer) updateCrypto() error {
if c.crypto == nil {
uiConfig := c.acct.UiConfig()
c.crypto = newCryptoStatus(&uiConfig)
c.crypto = newCryptoStatus(uiConfig)
}
var err error
// Check if signKey is empty so we only run this once
@ -924,11 +924,11 @@ type headerEditor struct {
header *mail.Header
focused bool
input *ui.TextInput
uiConfig config.UIConfig
uiConfig *config.UIConfig
}
func newHeaderEditor(name string, h *mail.Header,
uiConfig config.UIConfig) *headerEditor {
uiConfig *config.UIConfig) *headerEditor {
he := &headerEditor{
input: ui.NewTextInput("", uiConfig),
name: name,