Merge branch 'maintenance'
This commit is contained in:
commit
e04beceaec
|
@ -17,8 +17,8 @@ buildscript {
|
|||
allprojects {
|
||||
ext {
|
||||
projectGroupId = 'org.mariotaku.twidere'
|
||||
projectVersionCode = 515
|
||||
projectVersionName = '4.1.6'
|
||||
projectVersionCode = 517
|
||||
projectVersionName = '4.1.8'
|
||||
|
||||
globalCompileSdkVersion = 30
|
||||
globalBuildToolsVersion = "30.0.3"
|
||||
|
|
|
@ -703,6 +703,7 @@
|
|||
<provider
|
||||
android:name=".provider.ShareProvider"
|
||||
android:authorities="twidere.share"
|
||||
android:grantUriPermissions="true"
|
||||
android:exported="true"
|
||||
tools:ignore="ExportedContentProvider"/>
|
||||
<provider
|
||||
|
|
|
@ -128,8 +128,12 @@ class StatusDetailsAdapter(
|
|||
ITEM_IDX_CONVERSATION -> {
|
||||
data?.let { data ->
|
||||
var idx = position - getIndexStart(ITEM_IDX_CONVERSATION)
|
||||
if (data[idx].is_filtered) idx++
|
||||
return data[idx]
|
||||
if (idx in data.indices) {
|
||||
if (data[idx].is_filtered) {
|
||||
idx++
|
||||
}
|
||||
return data[idx]
|
||||
}
|
||||
}
|
||||
}
|
||||
ITEM_IDX_REPLY -> {
|
||||
|
@ -137,8 +141,12 @@ class StatusDetailsAdapter(
|
|||
var idx = position - getIndexStart(ITEM_IDX_CONVERSATION) -
|
||||
getTypeCount(ITEM_IDX_CONVERSATION) - getTypeCount(ITEM_IDX_STATUS) +
|
||||
replyStart
|
||||
if (data[idx].is_filtered) idx++
|
||||
return data[idx]
|
||||
if (idx in data.indices) {
|
||||
if (data[idx].is_filtered) {
|
||||
idx++
|
||||
}
|
||||
return data[idx]
|
||||
}
|
||||
}
|
||||
}
|
||||
ITEM_IDX_STATUS -> {
|
||||
|
|
|
@ -213,7 +213,9 @@ abstract class AbsContentListViewFragment<A : ListAdapter> : BaseFragment(),
|
|||
val density = resources.displayMetrics.density
|
||||
val progressCircleDiameter = swipeLayout.progressCircleDiameter
|
||||
val controlBarOffsetPixels =
|
||||
(activity.controlBarHeight * (1 - activity.controlBarOffset)).roundToInt()
|
||||
((activity.controlBarHeight * (1 - activity.controlBarOffset)).takeIf { !it.isNaN() }
|
||||
?: 0f)
|
||||
.roundToInt()
|
||||
val swipeStart = systemWindowsInsets.top - controlBarOffsetPixels - progressCircleDiameter
|
||||
// 64: SwipeRefreshLayout.DEFAULT_CIRCLE_TARGET
|
||||
val swipeDistance = (64 * density).roundToInt()
|
||||
|
|
Loading…
Reference in New Issue