MIOLO20
Carregando...
Procurando...
Nenhuma entrada encontrada
munorderedlist.class
Ir para a documentação deste ficheiro.
1<?php
2
4{
5 public $content;
6
7
8 public function __construct( $name = '', $options = array() )
9 {
10 parent::__construct( $name, '', $options );
11
12 $this->formMode = MControl::FORM_MODE_WHOLE_ROW;
13 }
14
15
16 public function addOption( $value, $li = true )
17 {
18 $o = new MOption( '', $value );
19 $o->type = $li ? 'circle' : 'circle';
20 $this->options[] = $o;
21 }
22
23
24 public function addOptions( $array )
25 {
26 if ( ! is_array( $array ) )
27 {
28 $array = array( $array );
29 }
30
31 foreach ( $array as $value )
32 {
33 $this->addOption( $value );
34 }
35 }
36
37
38 public function generateInner()
39 {
40 if ( $this->readonly )
41 {
42 return;
43 }
44
45 $this->content = '';
46
47 foreach ( $this->options as $o )
48 {
49 $o->value = $this->painter->generateToString( $o->value );
50 $this->content .= $this->painter->UnOrderedListItem( $o );
51 }
52
53 $this->inner = $this->getRender( 'unorderedlist' );
54 }
55}
56
57?>
const FORM_MODE_WHOLE_ROW
Definição mcontrol.class:41
getRender( $method)
Definição mcontrol.class:833
__construct( $name='', $options=array())
addOption( $value, $li=true)