vcl: move functions from window.cxx to stacking.cxx

Change-Id: I397c7b446d9a93916cd6489ee68178bdde3a45cf