When visible changed, do setup or unwatch and call visible_callback
432335
def visible(self, visible):
        """"""
        self._visible = visible

        if visible and len(self.panel.objects) == 0:
            self.setup()
            self.select.visible = True
            self.control_panel.extend(self.controls)
            self.panel.extend(self.children)
        elif not visible and len(self.panel.objects) > 0:
            self.unwatch()
            # do children
            self.select.visible = False
            self.control_panel.clear()
            self.search.visible = False
            self.add.visible = False
            self.panel.clear()
        if self.visible_callback:
            self.visible_callback(visible)
827020
function(options) {
        var layer = this.layer;
        layer.events.triggerEvent("loadstart", {filter: layer.filter});
        layer.protocol.read(OpenLayers.Util.applyDefaults({
            callback: this.merge,
            filter: layer.filter,
            scope: this
        }, options));
        layer.events.un({
            "visibilitychanged": this.load,
            scope: this
        });
    }
989603
public void setAlarmsVisible(final boolean VISIBLE) {
        if (null == alarmsVisible) {
            _alarmsVisible = VISIBLE;
            fireUpdateEvent(REDRAW_EVENT);
        } else {
            alarmsVisible.set(VISIBLE);
        }
    }
550628
def _track_modify(self, cls, name, detail, keep, trace):
        
        self._observers[cls].modify(name, detail, keep, trace)
1223912
@Override protected void onVisibilityChanged(View changedView, int visibility) {
    super.onVisibilityChanged(changedView, visibility);
    if (changedView != this) {
      return;
    }

    if (visibility == View.VISIBLE) {
      resumePresenter();
    } else {
      pausePresenter();
    }
  }
291099
function mxVisibleChange(model, cell, visible)
{
	this.model = model;
	this.cell = cell;
	this.visible = visible;
	this.previous = visible;
}
51736
public void setThresholdVisible(final boolean VISIBLE) {
        if (null == thresholdVisible) {
            _thresholdVisible = VISIBLE;
            fireUpdateEvent(VISIBILITY_EVENT);
        } else {
            thresholdVisible.set(VISIBLE);
        }
    }
1010307
@Api
	public void setVisible(boolean visible) {
		if (visible != this.visible) {
			this.visible = visible;
			updateShowing(false);
			handlerManager.fireEvent(new LayerShownEvent(this));
		}
	}
166568
function () {
                        for (var name in observing) {
                            var ob = observing[name];
                            ob.observe.obj.unbind(ob.observe.attr, onchanged);
                            delete observing[name];
                        }
                    }
879239
def visible(self, visible):
        """"""
        self._visible = visible
        if visible and len(self.panel.objects) == 0:
            self.setup()
            self.panel.extend(self.children)
        elif not visible and len(self.panel.objects) > 0:
            self.unwatch()
            self.panel.clear()
        if self.visible_callback:
            self.visible_callback(visible)
776886
function(visible) {
            var e = document.getElementById('imc_loading');

            if (typeof visible == 'undefined') {
                return e.classList.contains('loading');
            }

            if (visible) {
                e.classList.add('loading');
            }
            else {
                e.classList.remove('loading');
            }

            return visible;
        }
115878
def orify(event, changed_callback):
    '''
    

    '''
    event.changed = changed_callback
    if not hasattr(event, '_set'):
        # `set`/`clear` methods have not been overridden on event yet.
        # Override methods to call `changed_callback` after performing default
        # action.
        event._set = event.set
        event._clear = event.clear
        event.set = lambda: or_set(event)
        event.clear = lambda: or_clear(event)
663842
public void setSecondsVisible(boolean VISIBLE) { 
        if (null == secondsVisible) {
            _secondsVisible = VISIBLE;
            fireUpdateEvent(VISIBILITY_EVENT);
        } else {
            secondsVisible.set(VISIBLE);
        }
    }
1065832
def view_changed(self):
        
        if self._resetting:
            return  # don't update anything while resetting (are in set_range)
        if self._viewbox:
            # Set range if necessary
            if self._xlim is None:
                args = self._set_range_args or ()
                self.set_range(*args)
            # Store default state if we have not set it yet
            if self._default_state is None:
                self.set_default_state()
            # Do the actual update
            self._update_transform()
580076
public void setHourTickMarksVisible(final boolean VISIBLE) {
        if (null == hourTickMarksVisible) {
            _hourTickMarksVisible = VISIBLE;
            fireUpdateEvent(REDRAW_EVENT);
        } else {
            hourTickMarksVisible.set(VISIBLE);
        }
    }
150350
function (root, options, watchCallback, initCallback) {
      if (!watchCallback) {
        watchCallback = options;
        options = {}
      }
      lessWatchCompilerUtilsModule.walk(root, options, function (err, files) {
          if (err) throw err;
          lessWatchCompilerUtilsModule.fileWatcher(root, files, options, filelist, fileimportlist, watchCallback);
          for (var i in files) {
            lessWatchCompilerUtilsModule.fileWatcher(i, files, options, filelist, fileimportlist, watchCallback);
          }
          watchCallback(files, null, null, fileimportlist);
        },
        initCallback);
    }
1075996
def visible(self):
        
        delete = self._element.delete_
        if delete is None:
            return False
        return False if delete.val else True