Handle layer inheriting.