Move select functionality from msglist to msgstore
Remove msglist Next and Prev commands Signed-off-by: Kevin Kuehler <kkuehler@brave.com>
This commit is contained in:
parent
d1df710328
commit
32f970e053
5 changed files with 67 additions and 46 deletions
commands/msg
|
@ -34,7 +34,8 @@ func Archive(aerc *widgets.Aerc, args []string) error {
|
|||
msg := widget.SelectedMessage()
|
||||
store := widget.Store()
|
||||
archiveDir := acct.AccountConfig().Archive
|
||||
acct.Messages().Next()
|
||||
store.Next()
|
||||
acct.Messages().Scroll()
|
||||
|
||||
switch args[1] {
|
||||
case ARCHIVE_MONTH:
|
||||
|
|
|
@ -31,7 +31,8 @@ func DeleteMessage(aerc *widgets.Aerc, args []string) error {
|
|||
if isMsgView {
|
||||
aerc.RemoveTab(widget)
|
||||
}
|
||||
acct.Messages().Next()
|
||||
store.Next()
|
||||
acct.Messages().Scroll()
|
||||
store.Delete([]uint32{msg.Uid}, func(msg types.WorkerMessage) {
|
||||
switch msg := msg.(type) {
|
||||
case *types.Done:
|
||||
|
|
|
@ -45,7 +45,8 @@ func Move(aerc *widgets.Aerc, args []string) error {
|
|||
if isMsgView {
|
||||
aerc.RemoveTab(widget)
|
||||
}
|
||||
acct.Messages().Next()
|
||||
store.Next()
|
||||
acct.Messages().Scroll()
|
||||
store.Move([]uint32{msg.Uid}, args[optind], createParents, func(
|
||||
msg types.WorkerMessage) {
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue