protect minimization status

as minimize is now used from a command directly, the pane status needs
to be checked before reading and writing sizes.

panes that aren't open or already in the desired state will be ignored.