abo-abo / ace-window

Quickly switch windows in Emacs
970 stars 86 forks source link

Fix aw-switch-buffer-other-window bug #158

Closed nickdrozd closed 5 years ago

nickdrozd commented 5 years ago

When aw-switch-buffer-other-window is executed, it switches to the selected window, changes the buffer, and then switches back. If the buffer-switching function is canceled, the window won't get switched back. Using unwind-protect ensures that the function ends with the starting window selected.

nickdrozd commented 5 years ago

I've had a few changes sitting around for a while, but I couldn't submit because of the copyright thing. But I signed the papers recently, so that's no problem now.

abo-abo commented 5 years ago

Thanks.