mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
FindDialog: trying to remove item from immutable list
This commit is contained in:
@@ -1464,13 +1464,13 @@ public class FindDialog extends DialogWrapper {
|
||||
if (myDirectoryComboBox.getItemCount() > 0){
|
||||
myReplaceComboBox.removeAllItems();
|
||||
}
|
||||
int ignoredIdx = -1;
|
||||
if (directoryName != null && !directoryName.isEmpty()){
|
||||
if (strings.contains(directoryName)){
|
||||
strings.remove(directoryName);
|
||||
}
|
||||
ignoredIdx = strings.indexOf(directoryName);
|
||||
myDirectoryComboBox.addItem(directoryName);
|
||||
}
|
||||
for(int i = strings.size() - 1; i >= 0; i--){
|
||||
if (i == ignoredIdx) continue;
|
||||
myDirectoryComboBox.addItem(strings.get(i));
|
||||
}
|
||||
if (myDirectoryComboBox.getItemCount() == 0){
|
||||
|
||||
Reference in New Issue
Block a user