Code Duplication    Length = 7-8 lines in 2 locations

Ajax/semantic/html/collections/menus/HtmlMenu.php 1 location

@@ 126-133 (lines=8) @@
123
		return $popup;
124
	}
125
126
	public function addDropdownAsItem($value, $items=NULL) {
127
		$dd=$value;
128
		if (\is_string($value)) {
129
			$dd=new HtmlDropdown("dropdown-" . $this->identifier . "-" . $this->count(), $value, $items);
130
		}
131
		$this->addItem($dd);
132
		return $dd;
133
	}
134
135
	/**
136
	 *

Ajax/common/Widget.php 1 location

@@ 171-177 (lines=7) @@
168
		return $this;
169
	}
170
171
	public function addDropdownInToolbar($value,$items=NULL,$callback=NULL){
172
		$dd=$value;
173
		if (\is_string($value)) {
174
			$dd=new HtmlDropdown("dropdown-". $this->identifier."-".$value, $value, $items);
175
		}
176
		return $this->addInToolbar($dd,$callback);
177
	}
178
179
	public function addButtonInToolbar($caption,$callback=NULL){
180
		$bt=new HtmlButton("",$caption);