isLoading = loading;
updateBackground(loading);
}
public void updateBackground(final boolean readonly) {
final JBViewport viewport = UIUtil.getParentOfType(JBViewport.class, this);
if (viewport != null) {
new ConditionalLaterInvocator() {
@Override
public void execute() {
DataGridTextAttributes attributes = cellRenderer.getAttributes();
Color background = readonly ?
attributes.getLoadingData(false).getBgColor() :
attributes.getPlainData(false, false).getBgColor();
viewport.setBackground(background);
viewport.repaint();
}
}.start();
}
}