Fixed layer to selection bug