From 321fae15a7f77a5a11775bb5676cb58a69c3c274 Mon Sep 17 00:00:00 2001 From: Igor Slobodskov Date: Tue, 25 Oct 2022 16:41:38 +0200 Subject: [PATCH] [DS-3533] format code GitOrigin-RevId: 385fc02eff0a4e80a0b74240817dee76df105f74 --- .../notebooks/visualization/NotebookCellInlayManager.kt | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/notebooks/visualization/src/org/jetbrains/plugins/notebooks/visualization/NotebookCellInlayManager.kt b/notebooks/visualization/src/org/jetbrains/plugins/notebooks/visualization/NotebookCellInlayManager.kt index 915f5daacbf4..bb40117841a6 100644 --- a/notebooks/visualization/src/org/jetbrains/plugins/notebooks/visualization/NotebookCellInlayManager.kt +++ b/notebooks/visualization/src/org/jetbrains/plugins/notebooks/visualization/NotebookCellInlayManager.kt @@ -286,7 +286,8 @@ class NotebookCellInlayManager private constructor(val editor: EditorImpl) { } if (Disposer.isDisposed(inlay)) { disposable.dispose() - } else { + } + else { Disposer.register(inlay, disposable) } } @@ -333,7 +334,7 @@ class NotebookCellInlayManager private constructor(val editor: EditorImpl) { textAttributesForHighlighter(), HighlighterTargetArea.LINES_IN_RANGE ) - highlighter.customRenderer = NotebookCellHighlighterRenderer + highlighter.customRenderer = NotebookCellHighlighterRenderer } } } @@ -406,7 +407,7 @@ private object NotebookCellHighlighterRenderer : CustomHighlighterRenderer { private class UpdateInlaysTask(private val manager: NotebookCellInlayManager, pointers: Collection? = null, private var updateAll: Boolean = false) : Update(Any()) { - private val pointersSet = pointers?.let{ SmartHashSet(pointers) } ?: SmartHashSet() + private val pointersSet = pointers?.let { SmartHashSet(pointers) } ?: SmartHashSet() override fun run() { if (updateAll) { @@ -414,7 +415,7 @@ private class UpdateInlaysTask(private val manager: NotebookCellInlayManager, return } - val linesList = pointersSet.mapNotNullTo(mutableListOf()){ it.get()?.lines } + val linesList = pointersSet.mapNotNullTo(mutableListOf()) { it.get()?.lines } linesList.sortBy { it.first } linesList.mergeAndJoinIntersections(listOf())