function addRow($id, $values = null, $buttons = null) { $row = new row($this->append(), $this->headers, array_merge(array(row::IDATTR => $id, 'buttons' => $buttons), $values)); if (is_array($b = $this->getButtons())) { foreach ($b as $action => $ar) { $row->setButton($action, $ar); } } return $row; }