mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-08 15:09:39 +07:00
[bdt] BDIDE-3618 Minimap (fix): Fixed text in settings about fileTypes and also some minor code cleanup.
GitOrigin-RevId: 289338c32540d62ef3b45926e066a409e575bbdf
This commit is contained in:
committed by
intellij-monorepo-bot
parent
8a3469cee7
commit
d41d4082ad
@@ -14,7 +14,7 @@ settings.enable.scope=Scope:
|
||||
settings.enable.all=All files
|
||||
settings.filter=Image filter:
|
||||
settings.filter.hint=Filter algorithm for Minimap image
|
||||
settings.file.types=Show for file types:
|
||||
settings.file.types=Show for file extensions:
|
||||
settings.alignment=Position:
|
||||
settings.left=Left
|
||||
settings.right=Right
|
||||
|
||||
@@ -3,7 +3,6 @@ package com.intellij.ide.minimap
|
||||
|
||||
import com.intellij.concurrency.JobScheduler
|
||||
import com.intellij.ide.minimap.settings.MinimapSettings
|
||||
import com.intellij.openapi.Disposable
|
||||
import com.intellij.openapi.application.invokeAndWaitIfNeeded
|
||||
import com.intellij.openapi.editor.Editor
|
||||
import com.intellij.util.ui.ImageUtil
|
||||
@@ -16,7 +15,7 @@ import kotlin.math.ceil
|
||||
/**
|
||||
* A rendered minimap of a document.
|
||||
*/
|
||||
class MinimapImage(parentDisposable: Disposable) {
|
||||
class MinimapImage {
|
||||
|
||||
companion object {
|
||||
private const val UPDATE_DELAY_MILLIS = 200L
|
||||
@@ -152,9 +151,6 @@ class MinimapImage(parentDisposable: Disposable) {
|
||||
try {
|
||||
innerUpdate(editor, visibleHeight, visibleWidth, minimapHeight)
|
||||
}
|
||||
catch (e: Exception) {
|
||||
e.printStackTrace()
|
||||
}
|
||||
finally {
|
||||
scheduled.set(false)
|
||||
}
|
||||
|
||||
@@ -156,7 +156,7 @@ class MinimapPanel(private val parentDisposable: Disposable, private val editor:
|
||||
var map = minimapImageSoftReference.get()
|
||||
|
||||
if (map == null) {
|
||||
map = MinimapImage(parentDisposable)
|
||||
map = MinimapImage()
|
||||
map.onImageReady = { repaint() }
|
||||
minimapImageSoftReference = SoftReference(map)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user