Bit more GUI stuff

Also moved CWD capture into it's own file