This commit is contained in:
Alexey Kudravtsev
2014-11-26 18:41:10 +03:00
parent 507aaad51e
commit 3ec9dad76a
3 changed files with 7 additions and 6 deletions
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2012 JetBrains s.r.o.
* Copyright 2000-2014 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -60,6 +60,7 @@ public class CompilerEncodingServiceImpl extends CompilerEncodingService {
}, false);
}
@NotNull
private Map<Module, Set<Charset>> computeModuleCharsetMap() {
final Map<Module, Set<Charset>> map = new THashMap<Module, Set<Charset>>();
final Map<VirtualFile, Charset> mappings = EncodingProjectManager.getInstance(myProject).getAllMappings();
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2009 JetBrains s.r.o.
* Copyright 2000-2014 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -68,7 +68,7 @@ public abstract class ChooseFileEncodingAction extends ComboBoxAction {
}
@Override
public void update(AnActionEvent e) {
public void update(@NotNull AnActionEvent e) {
}
@Override
@@ -89,7 +89,7 @@ public abstract class ChooseFileEncodingAction extends ComboBoxAction {
}
@Override
public void actionPerformed(final AnActionEvent e) {
public void actionPerformed(@NotNull final AnActionEvent e) {
chosen(myFile, NO_ENCODING);
}
}
@@ -1426,8 +1426,8 @@ public class ContainerUtil extends ContainerUtilRt {
}
@Contract(pure=true)
public static <T> T getFirstItem(@Nullable final Collection<T> items, @Nullable final T def) {
return items == null || items.isEmpty() ? def : items.iterator().next();
public static <T> T getFirstItem(@Nullable final Collection<T> items, @Nullable final T defaultResult) {
return items == null || items.isEmpty() ? defaultResult : items.iterator().next();
}
/**