|
@@ -34,6 +34,11 @@ class SquirrelOption {
|
|
* @var string
|
|
* @var string
|
|
*/
|
|
*/
|
|
var $caption;
|
|
var $caption;
|
|
|
|
+ /**
|
|
|
|
+ * Whether or not the caption text is allowed to wrap
|
|
|
|
+ * @var boolean
|
|
|
|
+ */
|
|
|
|
+ var $caption_wrap;
|
|
/**
|
|
/**
|
|
* The type of INPUT element
|
|
* The type of INPUT element
|
|
*
|
|
*
|
|
@@ -177,6 +182,7 @@ class SquirrelOption {
|
|
$this->raw_option_array = $raw_option_array;
|
|
$this->raw_option_array = $raw_option_array;
|
|
$this->name = $name;
|
|
$this->name = $name;
|
|
$this->caption = $caption;
|
|
$this->caption = $caption;
|
|
|
|
+ $this->caption_wrap = TRUE;
|
|
$this->type = $type;
|
|
$this->type = $type;
|
|
$this->refresh_level = $refresh_level;
|
|
$this->refresh_level = $refresh_level;
|
|
$this->possible_values = $possible_values;
|
|
$this->possible_values = $possible_values;
|
|
@@ -238,6 +244,14 @@ class SquirrelOption {
|
|
$this->new_value = $new_value;
|
|
$this->new_value = $new_value;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ /**
|
|
|
|
+ * Set whether the caption is allowed to wrap for this option.
|
|
|
|
+ * @param boolean $caption_wrap
|
|
|
|
+ */
|
|
|
|
+ function setCaptionWrap($caption_wrap) {
|
|
|
|
+ $this->caption_wrap = $caption_wrap;
|
|
|
|
+ }
|
|
|
|
+
|
|
/**
|
|
/**
|
|
* Set the size for this option.
|
|
* Set the size for this option.
|
|
* @param integer $size
|
|
* @param integer $size
|
|
@@ -910,6 +924,11 @@ function create_option_groups($optgrps, $optvals) {
|
|
(isset($optset['htmlencoded']) ? $optset['htmlencoded'] : false)
|
|
(isset($optset['htmlencoded']) ? $optset['htmlencoded'] : false)
|
|
);
|
|
);
|
|
|
|
|
|
|
|
+ /* If provided, set if the caption is allowed to wrap for this option. */
|
|
|
|
+ if (isset($optset['caption_wrap'])) {
|
|
|
|
+ $next_option->setCaptionWrap($optset['caption_wrap']);
|
|
|
|
+ }
|
|
|
|
+
|
|
/* If provided, set the size for this option. */
|
|
/* If provided, set the size for this option. */
|
|
if (isset($optset['size'])) {
|
|
if (isset($optset['size'])) {
|
|
$next_option->setSize($optset['size']);
|
|
$next_option->setSize($optset['size']);
|