mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
InlayHints: add example
GitOrigin-RevId: 5f0f2a16a1334061cf3d157fee378b18bba9b7b1
This commit is contained in:
committed by
intellij-monorepo-bot
parent
b524745152
commit
4115b05022
@@ -98,7 +98,7 @@ class AnnotationInlayProvider : InlayHintsProvider<AnnotationInlayProvider.Setti
|
||||
seq(
|
||||
psiSingleReference(smallText(attribute.name ?: ""), resolve = { attribute.reference?.resolve() }),
|
||||
smallText(" = "),
|
||||
smallText(attribute.value?.text ?: "") // TODO values references, at least annotations and enum names
|
||||
smallText(attribute.value?.text ?: "")
|
||||
)
|
||||
}
|
||||
}
|
||||
@@ -111,7 +111,13 @@ class AnnotationInlayProvider : InlayHintsProvider<AnnotationInlayProvider.Setti
|
||||
override val key: SettingsKey<Settings>
|
||||
get() = ourKey
|
||||
override val previewText: String?
|
||||
get() = "" // TODO
|
||||
get() = """
|
||||
class Demo {
|
||||
private static int pure(int x, int y) {
|
||||
return x * y + 10;
|
||||
}
|
||||
}
|
||||
""".trimIndent()
|
||||
|
||||
override fun createConfigurable(settings: Settings): ImmediateConfigurable {
|
||||
return object : ImmediateConfigurable {
|
||||
|
||||
Reference in New Issue
Block a user