fix bug to show right layer controls when layer is locked