From 020fc4442d5ef620afe7c2f4b87155429e5c5fdb Mon Sep 17 00:00:00 2001 From: Roman Chernyatchik Date: Tue, 11 Nov 2008 12:37:51 +0300 Subject: [PATCH] Use LOG.error instead of error message box --- .../editor/colors/impl/EditorColorsManagerImpl.java | 14 ++++++-------- .../src/messages/OptionsBundle.properties | 2 -- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/platform-impl/src/com/intellij/openapi/editor/colors/impl/EditorColorsManagerImpl.java b/platform-impl/src/com/intellij/openapi/editor/colors/impl/EditorColorsManagerImpl.java index 15aa6cb424..52e79a7a21 100644 --- a/platform-impl/src/com/intellij/openapi/editor/colors/impl/EditorColorsManagerImpl.java +++ b/platform-impl/src/com/intellij/openapi/editor/colors/impl/EditorColorsManagerImpl.java @@ -14,7 +14,6 @@ import com.intellij.openapi.editor.colors.EditorColorsManager; import com.intellij.openapi.editor.colors.EditorColorsScheme; import com.intellij.openapi.editor.colors.ex.DefaultColorSchemesManager; import com.intellij.openapi.options.*; -import com.intellij.openapi.ui.Messages; import com.intellij.openapi.util.*; import org.jdom.Document; import org.jdom.Element; @@ -114,9 +113,9 @@ public class EditorColorsManagerImpl extends EditorColorsManager try { final InputStream inputStream = DecodeDefaultsUtil.getDefaultsInputStream(provider, schemePath); if (inputStream == null) { - final String msg = OptionsBundle.message("options.color.schemes.load.read.error", schemePath); - LOG.info(msg); - Messages.showErrorDialog(msg, OptionsBundle.message("options.color.schemes.load.settings.title")); + // Error shouldn't occur during this operation + // thus we report error instead of info + LOG.error("Cannot read scheme from " + schemePath); continue; } @@ -135,13 +134,12 @@ public class EditorColorsManagerImpl extends EditorColorsManager ApplicationManager.getApplication().invokeLater( new Runnable(){ public void run() { - final String msg = OptionsBundle.message("options.color.schemes.load.read.error", schemePath + ": " + e.getLocalizedMessage()); - LOG.info(msg, e); - Messages.showErrorDialog(msg, OptionsBundle.message("options.color.schemes.load.settings.title")); + // Error shouldn't occur during this operation + // thus we report error instead of info + LOG.error("Cannot read scheme from " + schemePath + ": " + e.getLocalizedMessage(), e); } } ); - } } } diff --git a/platform-resources_eng/src/messages/OptionsBundle.properties b/platform-resources_eng/src/messages/OptionsBundle.properties index 542f9f1f3d..40669106eb 100644 --- a/platform-resources_eng/src/messages/OptionsBundle.properties +++ b/platform-resources_eng/src/messages/OptionsBundle.properties @@ -147,8 +147,6 @@ project.settings.display.name=Project Settings [{0}] template.project.settings.short.name=Template Project project.settings.short.name=Project options.color.schemes.presentable.name=Color schemes -options.color.schemes.load.settings.title=Load Settings -options.color.schemes.load.read.error=Cannot read scheme from {0} options.editor.settings.presentable.name=Editor settings options.java.attribute.descriptor.info=Info options.java.attribute.descriptor.server.problems=Problem from server -- 2.11.4.GIT