void (ItemEvent e) { if (e.getStateChange() == ItemEvent.SELECTED) { myCbVarType.setEnabled(Comparing.equal(myTypeSelector.getSelectedType(), CommonJavaRefactoringUtil.getTypeByExpressionWithExpectedType(myExpression))); } }