Removes all listeners.

If the event_name is specified, only listeners for that event will be
removed, otherwise all listeners for all events are removed.

@param null $event_name
767376
public function removeAllListeners($event_name=null)
    {
        // Read in our config/events file so that we have them all!
        if (! $this->have_read_from_file)
        {
            $this->readConfigFile();
        }

        if (! is_null($event_name))
        {
            unset($this->listeners[$event_name]);
        }
        else {
            $this->listeners = [];
        }

        return $this;
    }
551485
final public function deRegisterEvent($event_name)
    {
        if (isset($this->listeners[$event_name])) {
            unset($this->listeners[$event_name]);
        }
        return $this;
    }
806541
function()
	{
		// Cleans all objects where listeners have been added
		for (var i = 0; i < mxEvent.objects.length; i++)
		{
			if (mxEvent.objects[i].mxListenerList != null)
			{
				mxEvent.removeAllListeners(mxEvent.objects[i]);
			}
		}
	}
508999
function removeEvent(target, name, callback, capture) {
      if (target.removeEventListener) {
        target.removeEventListener(name, callback, capture || false);
      } else if (target.detachEvent) {
        target.detachEvent('on' + name, callback);
      }
    }
1000200
function(eventName, handler) {
    if (!this.__eventListeners) {
      this.__eventListeners = { };
    }
    if (this.__eventListeners[eventName]) {
      fabric.util.removeFromArray(this.__eventListeners[eventName], handler);
    }
  }
43954
function removeListener(event, eventHandler) {
    checkEventValid(event);

    if (listeners[event] && listeners[event].length) {
        var indexOfListener = listeners[event].indexOf(eventHandler);
        if (indexOfListener > -1) {
            listeners[event].splice(indexOfListener, 1);
        }
    }
}
15422
public function get_listener_priority( $event_name, $listener ) {

		if ( ! is_callable( $listener, true ) ) {
			throw new InvalidListenerException( '$listener must be callable.' );
		}

		$priority = has_filter( $event_name, $listener );

		if ( false === $priority ) {
			return null;
		}

		return $priority;
	}
172150
public function dispatchEvent($eventName, Event $event = null)
    {
        if ($this->eventDispatcher instanceof EventDispatcherInterface) {
            $this->eventDispatcher->dispatch($eventName, $event);
        }
    }
1158706
@SuppressWarnings("unchecked")
  public static <T extends LogEventListener> T removeListener(String name) {
    Map<String, LogEventListener> listeners = SelenideLogger.listeners.get();
    return listeners == null ? null : (T) listeners.remove(name);
  }
535309
public function detach(\Zend_EventManager_EventCollection $events)
    {
        foreach($this->listeners as $index => $listener) {
            if($events->detach($listener)) {
                unset($this->listeners[$index]);
            }
        }
    }
576094
function(event_name, event_object) {

		if (this._focused_element != event_object.target) {
			this._setTarget(null);
			this._focused_element = event_object.target;
		}

	}
154732
public function clearListeners($event = null)
	{
		if ($event)
		{
			$event = $this->resolveEventName($event);

			if (isset($this->listeners[$event]))
			{
				unset($this->listeners[$event]);
			}
		}
		else
		{
			$this->listeners = array();
		}

		return $this;
	}
731526
public function removeEvent($event, $table = null): void
    {
        unset($this->events[$table ?? static::TABLE_ANY][$event]);
    }
1366851
public function removeListener($event_name, $listener) {
	    	if(!is_callable($listener)){
	    		throw new \InvalidArgumentException("Argument 'listener' is not callable.");
	    	}

	        if (!isset($this->listeners[$event_name])) {
	            return false;
	        }

	        foreach($this->listeners[$event_name][2] as $index => $check) {
	            if ($check === $listener) {
	                unset($this->listeners[$event_name][1][$index]);
	                unset($this->listeners[$event_name][2][$index]);
	                return true;
	            }
	        }

	        return false;
	    }
619679
public function removeListener(string $eventName, $listener): void
    {
        $this->dispatcher->removeListener($eventName, $listener);
    }
52201
public function removeListener($name)
    {
        $listeners = $this->getConfig('listeners');
        if (!array_key_exists($name, $listeners)) {
            return false;
        }

        if (isset($this->_listenerInstances[$name])) {
            $this->_eventManager->off($this->_listenerInstances[$name]);
            unset($this->_listenerInstances[$name]);
        }

        unset($listeners[$name]);
        $this->_config['listeners'] = $listeners;
    }
1020584
def off(self, name, callback, once=False):
        

        if name not in self.event_listeners:
            return

        self.event_listeners[name].remove((callback, once))