Completed
Push — master ( 409900...f20dfb )
by Jean-Christophe
03:24
created

Dropdown   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 2
c 1
b 0
f 0
lcom 0
cbo 1
dl 0
loc 16
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 4 1
A setAction() 0 3 1
1
<?php
2
3
namespace Ajax\semantic\components;
4
5
use Ajax\JsUtils;
6
use Ajax\common\components\SimpleExtComponent;
7
8
class Dropdown extends SimpleExtComponent {
9
10
	public function __construct(JsUtils $js) {
11
		parent::__construct($js);
12
		$this->uiName="dropdown";
13
	}
14
15
	/**
16
	 * Sets a default action to occur
17
	 * @param string $action one of "select","auto","activate","combo","nothing","hide"
18
	 * @return \Ajax\semantic\components\Dropdown
19
	 */
20
	public function setAction($action){
21
		return $this->setParamCtrl("action", $action,array("select","auto","activate","combo","nothing","hide"));
22
	}
23
}