Fix ordering of panels in panel containers

An off-by-one error caused new panels to be inserted later
in the document than intended.
Merge pull request #4309 from atom/mb-fix-panel-order

Fix ordering of panels in panel containers