i am using SmartGWT , i have a listGrid with RecordClickHandler
and each record contains a checkBox,
when i click the checkBox the RecordClickHandler
is apply , but this is not the behavior that i want,
i want the check box to have a defferent behaviur than the record it self so can any one provide any help please ?
onRecordClick body :
public void onRecordClick(RecordClickEvent event) {
final int recordNumber = event.getRecordNum();
if(selectedJob == recordNumber) return;
boolean changeSelectedEquipment = true;
if(ClientFactoryImpl.isDirty()){
int tabNum = jobsContentView.getJobTabSet().getSelectedTabNumber();
switch (tabNum) {
case 0:
if(!jobsContentView.getJobsDetailsView().isValid()){
event.cancel();
changeSelectedEquipment = false;
dropBoxWindowManager.showError(jobsViewVocabularies.unableToSave());
jobsContentView.getJobTabSet().showErrorOnTab(tabNum, jobsViewVocabularies.unableToSave());
}
break;
case 1:
if(!jobsContentView.getJobsEquipmentUsedView().isValid()){
event.cancel();
changeSelectedEquipment = false;
dropBoxWindowManager.showError(jobsViewVocabularies.unableToSave());
jobsContentView.getJobTabSet().showErrorOnTab(tabNum, jobsViewVocabularies.unableToSave());
}
break;
default:
break;
}
}
if(changeSelectedEquipment && ClientFactoryImpl.isDirty()){
clientFactory.getJobsView().saveJobsView(null ,REDIRECTION_PLACE.TAB_CACHED, (((ListDataRow)(jobListGrid.getRecord(selectedJob))).getJobDetails().getJob().getJobId()));
((ListDataRow)jobListGrid.getRecord(selectedJob)).setIsCached(false);
}
if(changeSelectedEquipment){
updateNewRecord(recordNumber);
} else {
jobListGrid.deselectRecord(recordNumber);
jobListGrid.selectRecord(selectedJob);
}
}