Fixed fill history issue.

Declare coordinates array inside of loop and it works.
Why? Who knows.

Also added functionality to File > Quit / CTRL + Q