3 * Copyright (c) Xerox Corporation, Codendi Team, 2001-2009. All rights reserved
4 * Copyright 2013-2014,2016, Franck Villaume - TrivialDev
6 * This file is a part of Fusionforge.
8 * Fusionforge is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
13 * Fusionforge is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
18 * You should have received a copy of the GNU General Public License
19 * along with Fusionforge. If not, see <http://www.gnu.org/licenses/>.
22 class WidgetLayout_Row {
28 function __construct($id, $rank) {
31 $this->columns = array();
34 function setLayout(&$layout) {
35 $this->layout =& $layout;
39 $this->columns[] =& $c;
43 function display($readonly, $owner_id, $owner_type) {
45 echo $HTML->listTableTop(array(), array(), 'full', 'mainwidget_table'.$this->id);
46 echo html_ao('tr', array('style' => 'vertical-align:top;'));
47 $last = count($this->columns) - 1;
49 foreach($this->columns as $key => $nop) {
50 $this->columns[$key]->display($readonly, $owner_id, $owner_type, $is_last = ($i++ == $last));
52 echo html_ac(html_ap() -1);
53 echo $HTML->listTableBottom();
56 function getColumnIds() {
58 foreach($this->columns as $key => $nop) {
59 $ret[] = $this->columns[$key]->getColumnId();