mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-06 11:38:53 +07:00
[Java. Logging] Replace display name for logger variable and align it with the preferred logger combobox
IDEA-347382 GitOrigin-RevId: dec1fff935dd623808176ecf0bce37a47b2c4f37
This commit is contained in:
committed by
intellij-monorepo-bot
parent
9eac5d7b58
commit
5168d264d7
@@ -3,6 +3,7 @@ package com.intellij.ui.logging
|
||||
|
||||
import com.intellij.icons.AllIcons
|
||||
import com.intellij.java.JavaBundle
|
||||
import com.intellij.lang.LangBundle
|
||||
import com.intellij.lang.logging.JvmLogger
|
||||
import com.intellij.lang.logging.JvmLoggerFieldDelegate
|
||||
import com.intellij.lang.logging.UnspecifiedLogger
|
||||
@@ -33,24 +34,23 @@ class JvmLoggingConfigurable(private val project: Project) : DslConfigurableBase
|
||||
val loggers = JvmLogger.getAllLoggers(settings.loggerId == UnspecifiedLogger.UNSPECIFIED_LOGGER_ID)
|
||||
val panel = panel {
|
||||
group(JavaBundle.message("jvm.logging.configurable.java.group.display.name")) {
|
||||
row {
|
||||
label(JavaBundle.message("label.configurable.logger.generation.name"))
|
||||
row(JavaBundle.message("label.configurable.logger.generation.variable.name")) {
|
||||
loggerName = textField()
|
||||
.bindText(settings::loggerName.toNonNullableProperty(JvmLoggerFieldDelegate.LOGGER_IDENTIFIER))
|
||||
.cellValidation {
|
||||
addInputRule(JavaBundle.message("jvm.logging.configurable.invalid.identifier.error")) {
|
||||
!PsiNameHelper.getInstance(project).isIdentifier(it.text)
|
||||
.validationOnInput {
|
||||
if (PsiNameHelper.getInstance(project).isIdentifier(it.text)) {
|
||||
return@validationOnInput null
|
||||
}
|
||||
error(LangBundle.message("dialog.message.valid.identifier", it.text))
|
||||
}
|
||||
.align(AlignX.FILL)
|
||||
.widthGroup(JavaBundle.message("jvm.logging.configurable.java.group.display.name"))
|
||||
}
|
||||
row {
|
||||
label(JavaBundle.message("label.configurable.logger.type"))
|
||||
row(JavaBundle.message("label.configurable.logger.type")) {
|
||||
comboBox(loggers)
|
||||
.bindItem({ JvmLogger.getLoggerById(settings.loggerId) },
|
||||
{ settings.loggerId = it?.id })
|
||||
.onChanged { updateWarningRow(it.item) }
|
||||
.align(AlignX.FILL)
|
||||
.widthGroup(JavaBundle.message("jvm.logging.configurable.java.group.display.name"))
|
||||
}
|
||||
warningRow = row {
|
||||
icon(AllIcons.General.Warning).align(AlignY.TOP).gap(rightGap = RightGap.SMALL)
|
||||
|
||||
@@ -1021,12 +1021,11 @@ javadoc.type.parameters=Type parameters:
|
||||
jvm.logging.configurable.display.name = JVM Logging
|
||||
jvm.logging.configurable.id = jvm.logging
|
||||
jvm.logging.configurable.java.group.display.name = Java
|
||||
jvm.logging.configurable.invalid.identifier.error=Must be valid identifier
|
||||
jrt.node.short=[JRT]
|
||||
label.add.math.max.0.count.to.avoid.possible.semantics.change=Add Math.max(0, count) to avoid possible semantics change
|
||||
label.class.filter.editor.add.dialog.filter.pattern=Enter the filter pattern:
|
||||
label.configurable.logger.type=Logger:
|
||||
label.configurable.logger.generation.name= Logger's name:
|
||||
label.configurable.logger.generation.variable.name= Variable name:
|
||||
label.contract=&Contract:
|
||||
label.enter.fully.qualified.class.name=Enter fully qualified class name
|
||||
label.entry.points=Entry points:
|
||||
|
||||
Reference in New Issue
Block a user