:: Forum >>
How to disable selection on row click
I am using links in a row, but when I click on link I select the row too!
I dont want this. How to disable the selection of the row on click?
Better , I want to use selector to select the rows (multiple) not clicking on row.
btw very nice widget but some lack of documentation
best regard
ninnic
Saturday, December 31, 2005
I have found by myself:
...
// enable row selectors
obj.setSelectorVisible(true);
obj.setSelectorText(function(i){return this.getRowPosition(i)});
obj.setSelectorWidth(25);
// set row selection
obj.setSelectionMode("single-row");
obj.onRowMouseDown = function(event, index){ return true;}; //disable select on click
obj.onSelectorClicked = function(event, index) {
// window.location.href=this.getCellValue(0, index);
var v = this.getRowSelected(index);
obj.setRowSelected(!v, index);
return true;
};
obj.setCellLink("javascript:void(1);", 1);
obj.setCellTemplate(new AW.Templates.Link, 1); // and template
obj.onCellClicked = function(event, col, row){if (col==1 ) alert( this.getCellText(col, row));};
...
in this way you can select rows clicking on selector and have links in the cells without problems
bye
ninnic
Saturday, December 31, 2005
There is an easier way.
[CODE]
.aw-cells-selected {background: none;}
.aw-rows-selected {background:none;}
[/CODE]
Tony
Saturday, December 31, 2005
thanks for suggestion but I dont want to hide selection but select using selector column so I need to see which row is selected or not
my solution works
ninnic
Sunday, January 1, 2006
This topic is archived.
Back to support forum
Forum search