From c1dd2b6009d0629f788cb6dc5f1c328c0e4e81a7 Mon Sep 17 00:00:00 2001 From: shish Date: Thu, 12 Jul 2007 08:50:32 +0000 Subject: [PATCH] better variable names git-svn-id: file:///home/shish/svn/shimmie2/trunk@270 7f39781d-f577-437e-ae19-be835c7a54ca --- core/event.class.php | 8 +++++--- core/util.inc.php | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/core/event.class.php b/core/event.class.php index 7135637a..48a4f390 100644 --- a/core/event.class.php +++ b/core/event.class.php @@ -4,10 +4,12 @@ * generic parent class */ class Event { - var $_live = true; + var $vetoed = false; + var $veto_reason; - public function veto() { - $this->_live = false; + public function veto($reason="") { + $this->vetoed = true; + $this->veto_reason = $reason; } } ?> diff --git a/core/util.inc.php b/core/util.inc.php index ab68df3f..16a78ee2 100644 --- a/core/util.inc.php +++ b/core/util.inc.php @@ -330,7 +330,7 @@ function send_event($event) { ksort($my_event_listeners); foreach($my_event_listeners as $listener) { $listener->receive_event($event); - if(!$event->_live) break; + if($event->vetoed) break; } }