bugfix: selection of hidden layers was damaged