added rowClicked event

This commit is contained in:
Peter Schojer
2008-06-05 13:10:18 +00:00
parent c7a3b3499d
commit 790a20ed20
5 changed files with 63 additions and 10 deletions

View File

@@ -49,6 +49,7 @@ const std::string Table::FIELD_ROW("row");
const std::string Table::FIELD_VAL("val");
const std::string Table::FIELD_CNT("cnt");
const std::string Table::EV_CELLCLICKED("click");
const std::string Table::EV_ROWCLICKED("row");
const std::string Table::EV_CELLVALUECHANGED("edit");
const std::string Table::EV_LOADDATA("load");
const std::string Table::EV_AFTERLOAD("afterload");
@@ -157,6 +158,15 @@ void Table::handleAjaxRequest(const Poco::Net::NameValueCollection& args, Poco::
cellClicked(this, ev);
response.send();
}
else if (ev == EV_ROWCLICKED)
{
if (row < 0 )
throw InvalidArgumentException("row out of range");
std::size_t theRow(row);
rowClicked(this, theRow);
response.send();
}
else if (ev == EV_CELLVALUECHANGED)
{
if (col < 0 || row < 0 || col >= getColumnCount())