diff --git a/build.gradle.kts b/build.gradle.kts index 6099299..aef1b37 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -6,7 +6,7 @@ plugins { } group = "com.tpuahsiew.wirc" -version = "0.1.10" +version = "0.1.11" // No project-level repositories{} block here: settings.gradle.kts sets // dependencyResolutionManagement.repositoriesMode = FAIL_ON_PROJECT_REPOS and already @@ -38,7 +38,7 @@ compose.desktop { appResourcesRootDir.set(project.file("installerResources")) targetFormats(TargetFormat.Msi, TargetFormat.Exe) packageName = "wIRC" - packageVersion = "0.1.10" + packageVersion = "0.1.11" windows { menuGroup = "wIRC" upgradeUuid = "8f14e45f-ceea-4a5e-9c3b-5b1f0e8c2b7a" diff --git a/src/main/kotlin/ui/ChannelScreen.kt b/src/main/kotlin/ui/ChannelScreen.kt index 685f964..a4580d6 100644 --- a/src/main/kotlin/ui/ChannelScreen.kt +++ b/src/main/kotlin/ui/ChannelScreen.kt @@ -1031,7 +1031,10 @@ fun MessageScrollback( ) { msg -> val ts = timeFormat.format(Date(msg.timestampMillis)) val bodyAnnotated = parseMircToAnnotatedString(msg.rawText, textColor) - val mentioned = isMention(msg.rawText) + // Only real messages get the mention tint. Join/part/quit/nick/mode lines + // always contain your nick when they're about you ("you joined #chan"), + // which used to light up every one of your own joins. + val mentioned = msg.kind in MENTION_KINDS && isMention(msg.rawText) val nickColor = if (displaySettings.nickColorsEnabled) colorForNick(msg.sender ?: "") else textColor val mutedColor = textColor.copy(alpha = 0.7f) val prefix = rowPrefix(msg, ts, mutedColor, nickColor) @@ -1399,6 +1402,8 @@ private fun MentionColorPickerDialog(currentArgb: Int, onDismiss: () -> Unit, on ) } +private val MENTION_KINDS = setOf(MessageKind.CHAT, MessageKind.ACTION, MessageKind.NOTICE) + @Composable private fun WindowSettingsPanel( displaySettings: WindowDisplaySettings,