Fixed bugs with "Change size" button.

Prior to commit, changing the size and going back to the matrix entry screen would display determinants and matrices from before.