Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    ListGridField – Icon type

    I have a ListGrid which contains a column set up like this:

    Code:
            ListGridField testField = new ListGridField("Test", 20);
            testField.setWidth(50);
            testField.setHidden(false);
            testField.setCanGroupBy(false);
            testField.setCanSort(false);
            testField.setAlign(Alignment.CENTER);
            testField.setType(ListGridFieldType.ICON);
            testField.setCellIcon("DynamicForm_drop.png");
            testField.addRecordClickHandler(new RecordClickHandler() {
                public void onRecordClick(RecordClickEvent event) {
                    //perform some action
                    }
                }
            });
    Under certain conditions, this action becomes invalid for a row. When this happens, I need to disable the icon for that row, and preferably, make the icon disappear for that row. The icon should still show in the rows for which it is still valid. Is there any way to do that – maybe something similar to overriding the canEditCell method?

    I am currently using SmartGwt 2.1, GWT 2.0.3, and IE8.

    Thank you!
Working...
X