Ensures that this layer is visible by turning on all parent layers \
        that it needs to based on its inheritance value.

def ensureVisible(self):
        """
        Ensures that this layer is visible by turning on all parent layers \
        that it needs to based on its inheritance value.
        """
        # make sure all parents are visible
        if self._parent and self._inheritVisibility:
            self._parent.ensureVisible()
        
        self._visible = True
        self.sync()