Split locate functions into separate file

The idea is to put them into the corresponding files once the
window/client/page/workspace/monitor structure starts evolving.