int () { final RunnerAndConfigurationSettings currentConfiguration = RunManager.getInstance(myProject).getSelectedConfiguration(); if (currentConfiguration == null && myDefaultConfiguration != -1) { return myDefaultConfiguration; } return currentConfiguration instanceof RunnerAndConfigurationSettingsImpl ? getValues() .indexOf(ItemWrapper.wrap(myProject, currentConfiguration)) : -1; }