Store current selected grammar when reconstructing the grammar popup menu

When reconstructing the grammar popup menu, we would reselect the old
grammar based on the document file type. This required that OakDocumentView
had focus and in the responder chain. But, in cases where it did not
have focus (filebrowser or htmloutput) we would select the wrong grammar
(first listed) in the popup menu.

So now we just store the current selected grammar and reset it
after we finish reconstructing the popup.