ItEr56S11CUEscaladoPantallaCargaRecursosEmpresaItEr55S15: Improved the implementation of ResoucesLoadPanel.setNameFilterDisabled.

Now the value of the filter is reset only when the disable value actually changes.
Besides, it's reset to the value it had prevoiusly, not to the first value.
This commit is contained in:
Jacobo Aragunde Pérez 2010-04-30 14:12:42 +02:00 committed by Javier Moran Rua
parent 41102d19e8
commit b9458dc93d

View file

@ -376,8 +376,12 @@ public class ResourcesLoadPanel extends HtmlMacroComponent {
}
public void setNameFilterDisabled(boolean disabled) {
filterByNamePosition = disabled? -1 : 0;
((Combobox) getFellow("filterByNameCombo")).setDisabled(disabled);
Combobox combo = ((Combobox) getFellow("filterByNameCombo"));
if(combo.isDisabled() != disabled) {
filterByNamePosition = disabled? -1 :
((Integer)combo.getSelectedItemApi().getValue()).intValue();
combo.setDisabled(disabled);
}
}
}