moved code to check redefined screen positions to separate function