diff options
author | xue <> | 2006-09-04 19:15:47 +0000 |
---|---|---|
committer | xue <> | 2006-09-04 19:15:47 +0000 |
commit | 56fee292c37e162c03fab9eeadd6a8b9ab85c251 (patch) | |
tree | 923510b93c707868098ae4e5f404eb3766a59553 /framework/Web/UI/WebControls/TTableRow.php | |
parent | b107cad91733d4a2a80f42cdbaab41a4f7b41c9d (diff) |
merge from 3.0 branch till 1387
Diffstat (limited to 'framework/Web/UI/WebControls/TTableRow.php')
-rw-r--r-- | framework/Web/UI/WebControls/TTableRow.php | 32 |
1 files changed, 27 insertions, 5 deletions
diff --git a/framework/Web/UI/WebControls/TTableRow.php b/framework/Web/UI/WebControls/TTableRow.php index b0e0bfbe..d4bf7984 100644 --- a/framework/Web/UI/WebControls/TTableRow.php +++ b/framework/Web/UI/WebControls/TTableRow.php @@ -121,20 +121,19 @@ class TTableRow extends TWebControl }
/**
- * @return string location of a row in a table. Defaults to 'Body'.
+ * @return TTableRowSection location of a row in a table. Defaults to TTableRowSection::Body.
*/
public function getTableSection()
{
- return $this->getViewState('TableSection','Body');
+ return $this->getViewState('TableSection',TTableRowSection::Body);
}
/**
- * @param string location of a row in a table. Valid values include 'Header', 'Footer' and 'Body'.
+ * @param TTableRowSection location of a row in a table.
*/
public function setTableSection($value)
{
- $value=TPropertyValue::ensureEnum($value,'Header','Body','Footer');
- $this->setViewState('TableSection',$value,'Body');
+ $this->setViewState('TableSection',TPropertyValue::ensureEnum($value,'TTableRowSection'),TTableRowSection::Body);
}
/**
@@ -184,4 +183,27 @@ class TTableCellCollection extends TControlCollection }
}
+
+/**
+ * TTableRowSection class.
+ * TTableRowSection defines the enumerable type for the possible table sections
+ * that a {@link TTableRow} can be within.
+ *
+ * The following enumerable values are defined:
+ * - Header: in table header
+ * - Body: in table body
+ * - Footer: in table footer
+ *
+ * @author Qiang Xue <qiang.xue@gmail.com>
+ * @version $Revision: $ $Date: $
+ * @package System.Web.UI.WebControls
+ * @since 3.0.4
+ */
+class TTableRowSection extends TEnumerable
+{
+ const Header='Header';
+ const Body='Body';
+ const Footer='Footer';
+}
+
?>
\ No newline at end of file |