ktlint: Fix violations regarding statement wrapping

Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
This commit is contained in:
Aayush Gupta 2026-01-21 16:57:25 +08:00
parent c60339fc58
commit 6190db7d2f
4 changed files with 8 additions and 4 deletions

View File

@ -35,4 +35,3 @@ ktlint_standard_parameter-list-wrapping = disabled
ktlint_standard_property-naming = disabled
ktlint_standard_spacing-between-declarations-with-annotations = disabled
ktlint_standard_spacing-between-declarations-with-comments = disabled
ktlint_standard_statement-wrapping = disabled

View File

@ -41,7 +41,10 @@ class StreamSegmentItem(
viewHolder.root.findViewById<TextView>(R.id.textViewStartSeconds).text =
Localization.getDurationString(item.startTimeSeconds.toLong())
viewHolder.root.setOnClickListener { onClick.onItemClick(this, item.startTimeSeconds) }
viewHolder.root.setOnLongClickListener { onClick.onItemLongClick(this, item.startTimeSeconds); true }
viewHolder.root.setOnLongClickListener {
onClick.onItemLongClick(this, item.startTimeSeconds)
true
}
viewHolder.root.isSelected = isSelected
}

View File

@ -64,6 +64,5 @@ private val linkHandler: YoutubeStreamLinkHandlerFactory = YoutubeStreamLinkHand
* @return the video id
*/
private fun getYouTubeId(url: String): String? {
return runCatching { linkHandler.getId(url) }.getOrNull()
}

View File

@ -43,7 +43,10 @@ class ChannelItem(
gesturesListener?.run {
viewHolder.root.setOnClickListener { selected(infoItem) }
viewHolder.root.setOnLongClickListener { held(infoItem); true }
viewHolder.root.setOnLongClickListener {
held(infoItem)
true
}
}
}