Author: Kore Nordmann Date: 2007-01-04 11:15:48 +0100 (Thu, 04 Jan 2007) New Revision: 4461
Log: - Rosolved task #9889: Throw meaningful exception if extension needed for driver is not available. # Actually using ezcBase::checkDependency() which calls die() instead of # throwing an exception Modified: trunk/Graph/src/driver/flash.php trunk/Graph/src/driver/gd.php trunk/Graph/src/driver/svg.php Modified: trunk/Graph/src/driver/flash.php =================================================================== --- trunk/Graph/src/driver/flash.php 2007-01-04 08:33:42 UTC (rev 4460) +++ trunk/Graph/src/driver/flash.php 2007-01-04 10:15:48 UTC (rev 4461) @@ -45,6 +45,7 @@ */ public function __construct( array $options = array() ) { + ezcBase::checkDependency( 'Graph', ezcBase::DEP_PHP_EXTENSION, 'ming' ); $this->options = new ezcGraphFlashDriverOptions( $options ); } Modified: trunk/Graph/src/driver/gd.php =================================================================== --- trunk/Graph/src/driver/gd.php 2007-01-04 08:33:42 UTC (rev 4460) +++ trunk/Graph/src/driver/gd.php 2007-01-04 10:15:48 UTC (rev 4461) @@ -66,6 +66,7 @@ */ public function __construct( array $options = array() ) { + ezcBase::checkDependency( 'Graph', ezcBase::DEP_PHP_EXTENSION, 'gd' ); $this->options = new ezcGraphGdDriverOptions( $options ); } Modified: trunk/Graph/src/driver/svg.php =================================================================== --- trunk/Graph/src/driver/svg.php 2007-01-04 08:33:42 UTC (rev 4460) +++ trunk/Graph/src/driver/svg.php 2007-01-04 10:15:48 UTC (rev 4461) @@ -71,6 +71,7 @@ */ public function __construct( array $options = array() ) { + ezcBase::checkDependency( 'Graph', ezcBase::DEP_PHP_EXTENSION, 'dom' ); $this->options = new ezcGraphSvgDriverOptions( $options ); } -- svn-components mailing list svn-components@lists.ez.no http://lists.ez.no/mailman/listinfo/svn-components