/* Create the global permissions object. */
// TODO: Convert to using Horde_Injector
$GLOBALS['perms'] = Horde_Perms::singleton();
+ $injector->setInstance('Horde_Perms', $GLOBALS['perms']);
+
+ /**
+ * Initialize notification object.
+ * No listeners are attached at this point.
+ */
+ $GLOBALS['notification'] = Horde_Notification::singleton();
+ $injector->setInstance('Horde_Notification', $GLOBALS['notification']);
}
/**
* Initialization. Does any necessary init needed to setup the full
* environment for the application.
*
- * Global variables defined:
- * <pre>
- * $notification - Horde_Notification object.
- * </pre>
- *
* Global constants defined:
* <pre>
* [APPNAME]_TEMPLATES - (string) Location of template files.
define($appname . '_TEMPLATES', $GLOBALS['registry']->get('templates'));
}
- $GLOBALS['notification'] = Horde_Notification::singleton();
$this->_init();
$this->_initNotification($GLOBALS['notification']);
}
/**
* Initialization for Notification system.
+ * This is run after _init() is called so app-specific code can appear
+ * inside.
*
* @param Horde_Notification_Handler_Base $notify The notification
* object.