Skip to content

Commit 333494e

Browse files
committed
add spe setInverted
1 parent 99e98ac commit 333494e

File tree

2 files changed

+18
-2
lines changed

2 files changed

+18
-2
lines changed

Ajax/semantic/html/modules/HtmlTab.php

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
*
1515
* @see http://semantic-ui.com/collections/tab.html
1616
* @author jc
17-
* @version 1.02
17+
* @version 1.0.2
1818
*/
1919
class HtmlTab extends HtmlSemCollection {
2020

@@ -29,6 +29,10 @@ public function __construct($identifier, $tabs = array()) {
2929
$this->content["menu"] = $menu;
3030
$this->addItems($tabs);
3131
}
32+
33+
public function getMenu(){
34+
return $this->content['menu'];
35+
}
3236

3337
/**
3438
*
@@ -288,4 +292,9 @@ public function compile(JsUtils $js = NULL, &$view = NULL) {
288292
$this->activate(0);
289293
return parent::compile($js, $view);
290294
}
295+
296+
public function setInverted($recursive=true){
297+
parent::setInverted($recursive);
298+
$this->content['menu']->addClass('inverted');
299+
}
291300
}

Ajax/semantic/widgets/datatable/DataTable.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
use Ajax\semantic\widgets\base\InstanceViewer;
1515
use Ajax\service\JArray;
1616
use Ajax\service\JString;
17+
use Ajax\semantic\html\base\HtmlSemDoubleElement;
1718

1819
/**
1920
* DataTable widget for displaying list of objects
@@ -710,5 +711,11 @@ public function setVisibleHover($_visibleHover) {
710711
public function getPaginationToolbar() {
711712
return $this->_paginationToolbar;
712713
}
713-
714+
715+
public function setInverted($recursive=true){
716+
$this->getHtmlComponent()->setInverted($recursive);
717+
if($this->_emptyMessage instanceof HtmlSemDoubleElement){
718+
$this->_emptyMessage->setInverted($recursive);
719+
}
720+
}
714721
}

0 commit comments

Comments
 (0)