mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2024-12-22 23:58:47 +01:00
Fix false positive with lint
This commit is contained in:
parent
d8bdf8e625
commit
fb42b869dd
@ -16,6 +16,7 @@
|
||||
|
||||
package im.vector.app.features.home.room.detail.timeline.helper
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.view.View
|
||||
import android.view.ViewGroup
|
||||
import android.widget.ProgressBar
|
||||
@ -126,12 +127,15 @@ private class ContentMediaProgressUpdater(private val progressLayout: ViewGroup,
|
||||
progressTextView.setTextColor(messageColorProvider.getMessageTextColor(SendState.SENDING))
|
||||
}
|
||||
|
||||
// Add SuppressLint to fix a false positive
|
||||
@SuppressLint("StringFormatMatches")
|
||||
private fun handleCompressingVideo(state: ContentUploadStateTracker.State.CompressingVideo) {
|
||||
progressLayout.visibility = View.VISIBLE
|
||||
progressBar.isVisible = true
|
||||
progressBar.isIndeterminate = false
|
||||
progressBar.progress = state.percent.toInt()
|
||||
progressTextView.isVisible = true
|
||||
// False positive is here...
|
||||
progressTextView.text = progressLayout.context.getString(R.string.send_file_step_compressing_video, state.percent.toInt())
|
||||
progressTextView.setTextColor(messageColorProvider.getMessageTextColor(SendState.SENDING))
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user