Advance cursor after :delete and :move

So that you can repeat the action on the next message if appropriate
This commit is contained in:
Drew DeVault 2019-05-19 18:21:02 -04:00
commit fa5d8d7a00
3 changed files with 7 additions and 4 deletions
commands/account

View file

@ -24,6 +24,7 @@ func DeleteMessage(aerc *widgets.Aerc, args []string) error {
}
store := acct.Messages().Store()
msg := acct.Messages().Selected()
acct.Messages().Next()
store.Delete([]uint32{msg.Uid}, func(msg types.WorkerMessage) {
switch msg := msg.(type) {
case *types.Done:

View file

@ -25,6 +25,7 @@ func Move(aerc *widgets.Aerc, args []string) error {
}
msg := acct.Messages().Selected()
store := acct.Messages().Store()
acct.Messages().Next()
store.Move([]uint32{msg.Uid}, args[1], func(msg types.WorkerMessage) {
switch msg := msg.(type) {
case *types.Done: