File: phpbb/event/dispatcher.php
Unmodified
Added
Modified
Removed
Line 13 | Line 13 |
---|
namespace phpbb\event;
|
namespace phpbb\event;
|
use Symfony\Component\EventDispatcher\ContainerAwareEventDispatcher;
| use Symfony\Component\EventDispatcher\EventDispatcher;
|
use Symfony\Component\EventDispatcher\Event;
/**
|
use Symfony\Component\EventDispatcher\Event;
/**
|
* Extension of the Symfony2 EventDispatcher
| * Extension of the Symfony EventDispatcher
|
* * It provides an additional `trigger_event` method, which * gives some syntactic sugar for dispatching events. Instead
| * * It provides an additional `trigger_event` method, which * gives some syntactic sugar for dispatching events. Instead
|
Line 30 | Line 30 |
---|
* extract($phpbb_dispatcher->trigger_event('core.index', compact($vars))); * */
|
* extract($phpbb_dispatcher->trigger_event('core.index', compact($vars))); * */
|
class dispatcher extends ContainerAwareEventDispatcher implements dispatcher_interface
| class dispatcher extends EventDispatcher implements dispatcher_interface
|
{ /** * @var bool
| { /** * @var bool
|
Line 40 | Line 40 |
---|
/** * {@inheritdoc} */
|
/** * {@inheritdoc} */
|
public function trigger_event($eventName, $data = array())
| public function trigger_event($eventName, $data = [])
|
{ $event = new \phpbb\event\data($data); $this->dispatch($eventName, $event);
| { $event = new \phpbb\event\data($data); $this->dispatch($eventName, $event);
|