aboutsummaryrefslogtreecommitdiff
path: root/core/src/main/kotlin/Model/Content.kt
diff options
context:
space:
mode:
authorDmitry Jemerov <yole@jetbrains.com>2016-01-08 19:57:23 +0100
committerDmitry Jemerov <yole@jetbrains.com>2016-01-08 19:57:23 +0100
commit628356d63443b11ff2221707c54a397f548d38a4 (patch)
tree54c8c5f1bcece2ce56f3cb14f504db52b144f196 /core/src/main/kotlin/Model/Content.kt
parent299b5c1566820128e3276f761404789e09b909a5 (diff)
downloaddokka-628356d63443b11ff2221707c54a397f548d38a4.tar.gz
dokka-628356d63443b11ff2221707c54a397f548d38a4.tar.bz2
dokka-628356d63443b11ff2221707c54a397f548d38a4.zip
link to JDK classes (KT-10452)
Diffstat (limited to 'core/src/main/kotlin/Model/Content.kt')
-rw-r--r--core/src/main/kotlin/Model/Content.kt6
1 files changed, 5 insertions, 1 deletions
diff --git a/core/src/main/kotlin/Model/Content.kt b/core/src/main/kotlin/Model/Content.kt
index 1bf1da48..4c69f6cb 100644
--- a/core/src/main/kotlin/Model/Content.kt
+++ b/core/src/main/kotlin/Model/Content.kt
@@ -158,7 +158,11 @@ fun ContentBlock.code(body: ContentBlock.() -> Unit) {
}
fun ContentBlock.link(to: DocumentationNode, body: ContentBlock.() -> Unit) {
- val block = ContentNodeDirectLink(to)
+ val block = if (to.kind == NodeKind.ExternalLink)
+ ContentExternalLink(to.name)
+ else
+ ContentNodeDirectLink(to)
+
block.body()
append(block)
}