cvs: pear /HTML_QuickForm/QuickForm hierselect.php

From: Date: Thu, 22 Jun 2006 09:43:00 +0000
Subject: cvs: pear /HTML_QuickForm/QuickForm hierselect.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-40863@lists.php.net to get a copy of this message
avb Thu Jun 22 09:43:00 2006 UTC Modified files: /pear/HTML_QuickForm/QuickForm hierselect.php Log: A better fix for bug #6766, one that doesn't break hierselect completely (bug #7961) http://cvs.php.net/viewvc.cgi/pear/HTML_QuickForm/QuickForm/hierselect.php?r1=1.16&r2=1.17&diff_format=u Index: pear/HTML_QuickForm/QuickForm/hierselect.php diff -u pear/HTML_QuickForm/QuickForm/hierselect.php:1.16 pear/HTML_QuickForm/QuickForm/hierselect.php:1.17 --- pear/HTML_QuickForm/QuickForm/hierselect.php:1.16 Sun Jun 18 20:01:01 2006 +++ pear/HTML_QuickForm/QuickForm/hierselect.php Thu Jun 22 09:43:00 2006 @@ -18,7 +18,7 @@ // | Alexey Borzov <avb@php.net> // +----------------------------------------------------------------------+ // -// $Id: hierselect.php,v 1.16 2006/06/18 20:01:01 avb Exp $ +// $Id: hierselect.php,v 1.17 2006/06/22 09:43:00 avb Exp $ require_once('HTML/QuickForm/group.php'); require_once('HTML/QuickForm/select.php'); @@ -251,9 +251,10 @@ */ function setValue($value) { - // fix for bug #6766. Hope this doesn't break anything, I don't like - // this whole _nbElements stupidity at all - // $this->_nbElements = count($value); + // fix for bug #6766. Hope this doesn't break anything more + // after bug #7961. Forgot that _nbElements was used in + // _createElements() called in several places... + $this->_nbElements = max($this->_nbElements, count($value)); parent::setValue($value); $this->_setOptions(); } // end func setValue

« previous php.pear.cvs (#40863) next »