Skip to content

Commit 04a99ee

Browse files
committed
Some fixes
1 parent 45fddd3 commit 04a99ee

File tree

4 files changed

+11
-13
lines changed

4 files changed

+11
-13
lines changed

src/main/kotlin/com/github/mr3zee/kotlinPlugins/KotlinPluginsExceptionReporter.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,7 @@ class KotlinPluginsExceptionReporterImpl(
207207

208208
private suspend fun processChunk(chunk: List<KotlinPluginDiscoveryUpdater.Discovery>) {
209209
chunk.forEach { discovery ->
210-
discoveryHandler.discoveredSync(discovery, redrawUpdateUpdate = false)
210+
discoveryHandler.discoveredSync(discovery, redrawAfterUpdate = false)
211211
}
212212

213213
logger.debug("Finished processing chunk of ${chunk.size} jars: ${chunk.map { "${it.pluginName} (${it.mavenId})" }}")
@@ -386,7 +386,7 @@ class KotlinPluginsExceptionReporterImpl(
386386
}
387387

388388
private inner class DiscoveryHandler : KotlinPluginDiscoveryUpdater {
389-
override suspend fun discoveredSync(discovery: KotlinPluginDiscoveryUpdater.Discovery, redrawUpdateUpdate: Boolean) {
389+
override suspend fun discoveredSync(discovery: KotlinPluginDiscoveryUpdater.Discovery, redrawAfterUpdate: Boolean) {
390390
val jarId = JarId(discovery.pluginName, discovery.mavenId, discovery.version)
391391

392392
var new = false
@@ -405,7 +405,7 @@ class KotlinPluginsExceptionReporterImpl(
405405

406406
refreshNotifications()
407407

408-
processDiscovery(discovery, redrawUpdateUpdate)
408+
processDiscovery(discovery, redrawAfterUpdate)
409409
}
410410
}
411411
}

src/main/kotlin/com/github/mr3zee/kotlinPlugins/KotlinPluginsSettings.kt

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -138,11 +138,12 @@ data class KotlinArtifactsRepository(
138138
enum class Type { URL, PATH }
139139

140140
override fun toString(): String {
141-
val message = when (type) {
142-
Type.URL -> KotlinPluginsBundle.message("repository.string.remote", name, value)
143-
Type.PATH -> KotlinPluginsBundle.message("repository.string.local", name, value)
141+
val prefix = when (type) {
142+
Type.URL -> "Remote"
143+
Type.PATH -> "Local"
144144
}
145-
return message
145+
146+
return "$prefix repository ($name): $value"
146147
}
147148
}
148149

src/main/kotlin/com/github/mr3zee/kotlinPlugins/KotlinPluginsStorage.kt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ class KotlinVersionMismatch(
107107
)
108108

109109
interface KotlinPluginDiscoveryUpdater {
110-
suspend fun discoveredSync(discovery: Discovery, redrawUpdateUpdate: Boolean = true)
110+
suspend fun discoveredSync(discovery: Discovery, redrawAfterUpdate: Boolean)
111111

112112
class Discovery(
113113
val pluginName: String,
@@ -143,7 +143,8 @@ suspend fun KotlinPluginDiscoveryUpdater.discoveredSync(
143143
checksum = checksum,
144144
isLocal = isLocal,
145145
kotlinVersionMismatch = kotlinVersionMismatch,
146-
)
146+
),
147+
redrawAfterUpdate = true,
147148
)
148149
}
149150

src/main/resources/messages/KotlinPluginsBundle.properties

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,6 @@ notification.group.displayName=Kotlin plugins
6464
status.failedToFetch=Failed to fetch
6565
status.notFound=Not found
6666

67-
# Repository string
68-
repository.string.remote=Remote repository ({0}): {1}
69-
repository.string.local=Local repository ({0}): {1}
70-
7167
# Links and other labels
7268
link.openSettings=Open Settings
7369
error.unknown.reason=Failed to load with unknown reason. <br/>Please check the log for details.

0 commit comments

Comments
 (0)