generalize the window managing process into window_manage, which handles dock apps...