diff --git a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/classpath/ClasspathPanelImpl.java b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/classpath/ClasspathPanelImpl.java index aebb2999c51d..7b9c41c5d1d8 100644 --- a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/classpath/ClasspathPanelImpl.java +++ b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/classpath/ClasspathPanelImpl.java @@ -175,7 +175,7 @@ public class ClasspathPanelImpl extends JPanel implements ClasspathPanel { } } }; - setFixedColumnWidth(ClasspathTableModel.EXPORT_COLUMN, ClasspathTableModel.getEXPORT_COLUMN_NAME()); + setFixedColumnWidth(ClasspathTableModel.EXPORT_COLUMN, ClasspathTableModel.getExportColumnName()); setFixedColumnWidth(ClasspathTableModel.SCOPE_COLUMN, DependencyScope.COMPILE.toString() + " "); // leave space for combobox border myEntryTable.getTableHeader().getColumnModel().getColumn(ClasspathTableModel.ITEM_COLUMN).setPreferredWidth(10000); // consume all available space diff --git a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/classpath/ClasspathTableModel.java b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/classpath/ClasspathTableModel.java index f1740fc48467..2e21f6dc2edf 100644 --- a/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/classpath/ClasspathTableModel.java +++ b/java/idea-ui/src/com/intellij/openapi/roots/ui/configuration/classpath/ClasspathTableModel.java @@ -38,7 +38,8 @@ import java.util.List; * @author nik */ class ClasspathTableModel extends ListTableModel> implements ItemRemovable { - private static final ColumnInfo, Boolean> EXPORT_COLUMN_INFO = new ColumnInfo, Boolean>(getEXPORT_COLUMN_NAME()) { + private static final ColumnInfo, Boolean> EXPORT_COLUMN_INFO = new ColumnInfo, Boolean>( + getExportColumnName()) { @Nullable @Override public Boolean valueOf(ClasspathTableItem item) { @@ -188,7 +189,7 @@ class ClasspathTableModel extends ListTableModel> implemen return ProjectBundle.message("modules.order.export.scope.column"); } - static String getEXPORT_COLUMN_NAME() { + static String getExportColumnName() { return ProjectBundle.message("modules.order.export.export.column"); } } diff --git a/platform/lang-impl/src/com/intellij/codeInsight/template/impl/LiveTemplateSettingsEditor.java b/platform/lang-impl/src/com/intellij/codeInsight/template/impl/LiveTemplateSettingsEditor.java index bafba5872632..d2b2a99b149d 100644 --- a/platform/lang-impl/src/com/intellij/codeInsight/template/impl/LiveTemplateSettingsEditor.java +++ b/platform/lang-impl/src/com/intellij/codeInsight/template/impl/LiveTemplateSettingsEditor.java @@ -218,7 +218,7 @@ public class LiveTemplateSettingsEditor extends JPanel { gbConstraints.gridx = 1; gbConstraints.insets = JBUI.insetsLeft(4); - myExpandByCombo = new ComboBox<>(new String[]{myDefaultShortcutItem, getSPACE(), getTAB(), getENTER(), getNONE()}); + myExpandByCombo = new ComboBox<>(new String[]{myDefaultShortcutItem, getSpace(), getTab(), getEnter(), getNone()}); myExpandByCombo.addItemListener(new ItemListener() { @Override public void itemStateChanged(@NotNull ItemEvent e) { @@ -226,13 +226,13 @@ public class LiveTemplateSettingsEditor extends JPanel { if(myDefaultShortcutItem.equals(selectedItem)) { myTemplate.setShortcutChar(TemplateSettings.DEFAULT_CHAR); } - else if(getTAB().equals(selectedItem)) { + else if(getTab().equals(selectedItem)) { myTemplate.setShortcutChar(TemplateSettings.TAB_CHAR); } - else if(getENTER().equals(selectedItem)) { + else if(getEnter().equals(selectedItem)) { myTemplate.setShortcutChar(TemplateSettings.ENTER_CHAR); } - else if (getSPACE().equals(selectedItem)) { + else if (getSpace().equals(selectedItem)) { myTemplate.setShortcutChar(TemplateSettings.SPACE_CHAR); } else { @@ -484,16 +484,16 @@ public class LiveTemplateSettingsEditor extends JPanel { myExpandByCombo.setSelectedItem(myDefaultShortcutItem); } else if(myTemplate.getShortcutChar() == TemplateSettings.TAB_CHAR) { - myExpandByCombo.setSelectedItem(getTAB()); + myExpandByCombo.setSelectedItem(getTab()); } else if(myTemplate.getShortcutChar() == TemplateSettings.ENTER_CHAR) { - myExpandByCombo.setSelectedItem(getENTER()); + myExpandByCombo.setSelectedItem(getEnter()); } else if (myTemplate.getShortcutChar() == TemplateSettings.SPACE_CHAR) { - myExpandByCombo.setSelectedItem(getSPACE()); + myExpandByCombo.setSelectedItem(getSpace()); } else { - myExpandByCombo.setSelectedItem(getNONE()); + myExpandByCombo.setSelectedItem(getNone()); } CommandProcessor.getInstance().executeCommand( @@ -588,19 +588,19 @@ public class LiveTemplateSettingsEditor extends JPanel { return map; } - private static String getSPACE() { + private static String getSpace() { return CodeInsightBundle.message("template.shortcut.space"); } - private static String getTAB() { + private static String getTab() { return CodeInsightBundle.message("template.shortcut.tab"); } - private static String getENTER() { + private static String getEnter() { return CodeInsightBundle.message("template.shortcut.enter"); } - private static String getNONE() { + private static String getNone() { return CodeInsightBundle.message("template.shortcut.none"); } } diff --git a/platform/lang-impl/src/com/intellij/ide/hierarchy/HierarchyBrowserBaseEx.java b/platform/lang-impl/src/com/intellij/ide/hierarchy/HierarchyBrowserBaseEx.java index b2d558d11284..fbbfac736bed 100644 --- a/platform/lang-impl/src/com/intellij/ide/hierarchy/HierarchyBrowserBaseEx.java +++ b/platform/lang-impl/src/com/intellij/ide/hierarchy/HierarchyBrowserBaseEx.java @@ -65,7 +65,7 @@ public abstract class HierarchyBrowserBaseEx extends HierarchyBrowserBase implem public static final String SCOPE_PROJECT = "Production"; /** - * Use {code {@link #getSCOPE_ALL()}} instead + * Use {code {@link #getScopeAll()}} instead */ @Deprecated public static final String SCOPE_ALL = "All"; @@ -124,7 +124,7 @@ public abstract class HierarchyBrowserBaseEx extends HierarchyBrowserBase implem for (Map.Entry entry : type2treeMap.entrySet()) { JTree tree = entry.getValue(); String type = entry.getKey(); - String scope = state.SCOPE != null ? state.SCOPE : getSCOPE_ALL(); + String scope = state.SCOPE != null ? state.SCOPE : getScopeAll(); OccurenceNavigatorSupport occurenceNavigatorSupport = new OccurenceNavigatorSupport(tree) { @Override @@ -710,9 +710,9 @@ public abstract class HierarchyBrowserBaseEx extends HierarchyBrowserBase implem private Collection getValidScopeNames() { List result = new ArrayList<>(); result.add(getScopeProject()); - result.add(getSCOPE_TEST()); - result.add(getSCOPE_ALL()); - result.add(getSCOPE_CLASS()); + result.add(getScopeTest()); + result.add(getScopeAll()); + result.add(getScopeClass()); final NamedScopesHolder[] holders = NamedScopesHolder.getAllNamedScopeHolders(myProject); for (NamedScopesHolder holder : holders) { @@ -795,7 +795,7 @@ public abstract class HierarchyBrowserBaseEx extends HierarchyBrowserBase implem public void actionPerformed(@NotNull AnActionEvent e) { EditScopesDialog.showDialog(myProject, null); if (!getValidScopeNames().contains(getCurrentScopeType())) { - selectScope(getSCOPE_ALL()); + selectScope(getScopeAll()); } } } @@ -805,15 +805,15 @@ public abstract class HierarchyBrowserBaseEx extends HierarchyBrowserBase implem return IdeBundle.message("hierarchy.scope.project"); } - public static String getSCOPE_ALL() { + public static String getScopeAll() { return IdeBundle.message("hierarchy.scope.all"); } - public static String getSCOPE_TEST() { + public static String getScopeTest() { return IdeBundle.message("hierarchy.scope.test"); } - public static String getSCOPE_CLASS() { + public static String getScopeClass() { return IdeBundle.message("hierarchy.scope.this.class"); } } \ No newline at end of file diff --git a/platform/lang-impl/src/com/intellij/ide/hierarchy/HierarchyTreeStructure.java b/platform/lang-impl/src/com/intellij/ide/hierarchy/HierarchyTreeStructure.java index 8de17d636294..88de1ec8b19d 100644 --- a/platform/lang-impl/src/com/intellij/ide/hierarchy/HierarchyTreeStructure.java +++ b/platform/lang-impl/src/com/intellij/ide/hierarchy/HierarchyTreeStructure.java @@ -136,13 +136,13 @@ public abstract class HierarchyTreeStructure extends AbstractTreeStructure { protected SearchScope getSearchScope(final String scopeType, final PsiElement thisClass) { SearchScope searchScope = GlobalSearchScope.allScope(myProject); - if (HierarchyBrowserBaseEx.getSCOPE_CLASS().equals(scopeType)) { + if (HierarchyBrowserBaseEx.getScopeClass().equals(scopeType)) { searchScope = new LocalSearchScope(thisClass); } else if (HierarchyBrowserBaseEx.getScopeProject().equals(scopeType)) { searchScope = GlobalSearchScopesCore.projectProductionScope(myProject); } - else if (HierarchyBrowserBaseEx.getSCOPE_TEST().equals(scopeType)) { + else if (HierarchyBrowserBaseEx.getScopeTest().equals(scopeType)) { searchScope = GlobalSearchScopesCore.projectTestScope(myProject); } else { final NamedScope namedScope = NamedScopesHolder.getScope(myProject, scopeType); @@ -154,18 +154,18 @@ public abstract class HierarchyTreeStructure extends AbstractTreeStructure { } protected boolean isInScope(final PsiElement baseClass, @NotNull PsiElement srcElement, final String scopeType) { - if (HierarchyBrowserBaseEx.getSCOPE_CLASS().equals(scopeType)) { + if (HierarchyBrowserBaseEx.getScopeClass().equals(scopeType)) { return PsiTreeUtil.isAncestor(baseClass, srcElement, true); } if (HierarchyBrowserBaseEx.getScopeProject().equals(scopeType)) { final VirtualFile virtualFile = srcElement.getContainingFile().getVirtualFile(); return virtualFile == null || !TestSourcesFilter.isTestSources(virtualFile, myProject); } - if (HierarchyBrowserBaseEx.getSCOPE_TEST().equals(scopeType)) { + if (HierarchyBrowserBaseEx.getScopeTest().equals(scopeType)) { final VirtualFile virtualFile = srcElement.getContainingFile().getVirtualFile(); return virtualFile == null || TestSourcesFilter.isTestSources(virtualFile, myProject); } - if (HierarchyBrowserBaseEx.getSCOPE_ALL().equals(scopeType)) { + if (HierarchyBrowserBaseEx.getScopeAll().equals(scopeType)) { return true; } final NamedScope namedScope = NamedScopesHolder.getScope(myProject, scopeType); diff --git a/platform/lang-impl/src/com/intellij/refactoring/rename/RenameDialog.java b/platform/lang-impl/src/com/intellij/refactoring/rename/RenameDialog.java index 220b39c383c7..0738517c0525 100644 --- a/platform/lang-impl/src/com/intellij/refactoring/rename/RenameDialog.java +++ b/platform/lang-impl/src/com/intellij/refactoring/rename/RenameDialog.java @@ -70,7 +70,7 @@ public class RenameDialog extends RefactoringDialog { myPsiElement = psiElement; myNameSuggestionContext = nameSuggestionContext; myEditor = editor; - setTitle(getREFACTORING_NAME()); + setTitle(getRefactoringName()); createNewNameComponent(); init(); @@ -364,7 +364,7 @@ public class RenameDialog extends RefactoringDialog { return myCbSearchInComments; } - private static String getREFACTORING_NAME() { + private static String getRefactoringName() { return RefactoringBundle.message("rename.title"); } } \ No newline at end of file