mirror of
https://github.com/element-hq/element-android
synced 2024-09-06 17:05:20 +00:00
Fix dependencies and code issues
This commit is contained in:
parent
bd6b441b2a
commit
f5cb980020
|
@ -47,6 +47,7 @@ ext.groups = [
|
||||||
],
|
],
|
||||||
mavenCentral: [
|
mavenCentral: [
|
||||||
regex: [
|
regex: [
|
||||||
|
'com\\.google\\.auto\\.*',
|
||||||
],
|
],
|
||||||
group: [
|
group: [
|
||||||
'app.cash.paparazzi',
|
'app.cash.paparazzi',
|
||||||
|
@ -101,6 +102,7 @@ ext.groups = [
|
||||||
'com.googlecode.json-simple',
|
'com.googlecode.json-simple',
|
||||||
'com.googlecode.libphonenumber',
|
'com.googlecode.libphonenumber',
|
||||||
'com.ibm.icu',
|
'com.ibm.icu',
|
||||||
|
'com.intellij',
|
||||||
'com.jakewharton.android.repackaged',
|
'com.jakewharton.android.repackaged',
|
||||||
'com.jakewharton.timber',
|
'com.jakewharton.timber',
|
||||||
'com.kgurgul.flipper',
|
'com.kgurgul.flipper',
|
||||||
|
|
|
@ -62,7 +62,7 @@ class JSonViewerFragment : Fragment(), MavericksView {
|
||||||
}
|
}
|
||||||
recyclerView = inflate.findViewById(R.id.jvRecyclerView)
|
recyclerView = inflate.findViewById(R.id.jvRecyclerView)
|
||||||
recyclerView.layoutManager =
|
recyclerView.layoutManager =
|
||||||
LinearLayoutManager(context, LinearLayoutManager.VERTICAL, false)
|
LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
||||||
recyclerView.setController(epoxyController)
|
recyclerView.setController(epoxyController)
|
||||||
epoxyController.setStyle(args?.styleProvider)
|
epoxyController.setStyle(args?.styleProvider)
|
||||||
registerForContextMenu(recyclerView)
|
registerForContextMenu(recyclerView)
|
||||||
|
|
|
@ -17,13 +17,6 @@ static def gitRevision() {
|
||||||
return cmd.execute().text.trim()
|
return cmd.execute().text.trim()
|
||||||
}
|
}
|
||||||
|
|
||||||
project.android.buildTypes.all { buildType ->
|
|
||||||
buildType.javaCompileOptions.annotationProcessorOptions.arguments =
|
|
||||||
[
|
|
||||||
validateEpoxyModelUsage: String.valueOf(buildType.name == 'debug')
|
|
||||||
]
|
|
||||||
}
|
|
||||||
|
|
||||||
initScreenshotTests(project)
|
initScreenshotTests(project)
|
||||||
|
|
||||||
android {
|
android {
|
||||||
|
|
|
@ -207,13 +207,13 @@ class AttachmentsPreviewFragment :
|
||||||
attachmentMiniaturePreviewController.callback = this
|
attachmentMiniaturePreviewController.callback = this
|
||||||
|
|
||||||
views.attachmentPreviewerMiniatureList.let {
|
views.attachmentPreviewerMiniatureList.let {
|
||||||
it.layoutManager = LinearLayoutManager(context, LinearLayoutManager.HORIZONTAL, false)
|
it.layoutManager = LinearLayoutManager(requireContext(), LinearLayoutManager.HORIZONTAL, false)
|
||||||
it.setHasFixedSize(true)
|
it.setHasFixedSize(true)
|
||||||
it.adapter = attachmentMiniaturePreviewController.adapter
|
it.adapter = attachmentMiniaturePreviewController.adapter
|
||||||
}
|
}
|
||||||
|
|
||||||
views.attachmentPreviewerBigList.let {
|
views.attachmentPreviewerBigList.let {
|
||||||
it.layoutManager = LinearLayoutManager(context, LinearLayoutManager.HORIZONTAL, false)
|
it.layoutManager = LinearLayoutManager(requireContext(), LinearLayoutManager.HORIZONTAL, false)
|
||||||
it.attachSnapHelperWithListener(
|
it.attachSnapHelperWithListener(
|
||||||
PagerSnapHelper(),
|
PagerSnapHelper(),
|
||||||
SnapOnScrollListener.Behavior.NOTIFY_ON_SCROLL_STATE_IDLE,
|
SnapOnScrollListener.Behavior.NOTIFY_ON_SCROLL_STATE_IDLE,
|
||||||
|
|
|
@ -1434,8 +1434,8 @@ class TimelineFragment :
|
||||||
timelineEventController.timeline = timelineViewModel.timeline
|
timelineEventController.timeline = timelineViewModel.timeline
|
||||||
|
|
||||||
views.timelineRecyclerView.trackItemsVisibilityChange()
|
views.timelineRecyclerView.trackItemsVisibilityChange()
|
||||||
layoutManager = object : LinearLayoutManager(context, RecyclerView.VERTICAL, true) {
|
layoutManager = object : LinearLayoutManager(requireContext(), RecyclerView.VERTICAL, true) {
|
||||||
override fun onLayoutCompleted(state: RecyclerView.State?) {
|
override fun onLayoutCompleted(state: RecyclerView.State) {
|
||||||
super.onLayoutCompleted(state)
|
super.onLayoutCompleted(state)
|
||||||
updateJumpToReadMarkerViewVisibility()
|
updateJumpToReadMarkerViewVisibility()
|
||||||
jumpToBottomViewVisibilityManager.maybeShowJumpToBottomViewVisibilityWithDelay()
|
jumpToBottomViewVisibilityManager.maybeShowJumpToBottomViewVisibilityWithDelay()
|
||||||
|
|
|
@ -285,7 +285,7 @@ class RoomListFragment :
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun setupRecyclerView() {
|
private fun setupRecyclerView() {
|
||||||
val layoutManager = LinearLayoutManager(context)
|
val layoutManager = LinearLayoutManager(requireContext())
|
||||||
stateRestorer = LayoutManagerStateRestorer(layoutManager).register()
|
stateRestorer = LayoutManagerStateRestorer(layoutManager).register()
|
||||||
views.roomListView.layoutManager = layoutManager
|
views.roomListView.layoutManager = layoutManager
|
||||||
views.roomListView.itemAnimator = RoomListAnimator()
|
views.roomListView.itemAnimator = RoomListAnimator()
|
||||||
|
|
|
@ -137,7 +137,7 @@ class HomeRoomListFragment :
|
||||||
|
|
||||||
private fun setupRecyclerView() {
|
private fun setupRecyclerView() {
|
||||||
views.stateView.state = StateView.State.Content
|
views.stateView.state = StateView.State.Content
|
||||||
val layoutManager = LinearLayoutManager(context)
|
val layoutManager = LinearLayoutManager(requireContext())
|
||||||
firstItemObserver = FirstItemUpdatedObserver(layoutManager) {
|
firstItemObserver = FirstItemUpdatedObserver(layoutManager) {
|
||||||
layoutManager.scrollToPosition(0)
|
layoutManager.scrollToPosition(0)
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,7 +20,7 @@ import android.content.Context
|
||||||
import android.os.Build
|
import android.os.Build
|
||||||
import androidx.annotation.MainThread
|
import androidx.annotation.MainThread
|
||||||
import androidx.annotation.VisibleForTesting
|
import androidx.annotation.VisibleForTesting
|
||||||
import androidx.annotation.VisibleForTesting.PRIVATE
|
import androidx.annotation.VisibleForTesting.Companion.PRIVATE
|
||||||
import androidx.biometric.BiometricManager
|
import androidx.biometric.BiometricManager
|
||||||
import androidx.biometric.BiometricManager.Authenticators.BIOMETRIC_STRONG
|
import androidx.biometric.BiometricManager.Authenticators.BIOMETRIC_STRONG
|
||||||
import androidx.biometric.BiometricManager.Authenticators.BIOMETRIC_WEAK
|
import androidx.biometric.BiometricManager.Authenticators.BIOMETRIC_WEAK
|
||||||
|
|
|
@ -65,7 +65,7 @@ class VectorSettingsNotificationsTroubleshootFragment :
|
||||||
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
|
override fun onViewCreated(view: View, savedInstanceState: Bundle?) {
|
||||||
super.onViewCreated(view, savedInstanceState)
|
super.onViewCreated(view, savedInstanceState)
|
||||||
|
|
||||||
val layoutManager = LinearLayoutManager(context)
|
val layoutManager = LinearLayoutManager(requireContext())
|
||||||
views.troubleshootTestRecyclerView.layoutManager = layoutManager
|
views.troubleshootTestRecyclerView.layoutManager = layoutManager
|
||||||
|
|
||||||
val dividerItemDecoration = DividerItemDecoration(view.context, layoutManager.orientation)
|
val dividerItemDecoration = DividerItemDecoration(view.context, layoutManager.orientation)
|
||||||
|
|
|
@ -214,7 +214,7 @@ class SpaceAddRoomFragment :
|
||||||
roomEpoxyController.submitList(it)
|
roomEpoxyController.submitList(it)
|
||||||
}
|
}
|
||||||
listenItemCount(viewModel.roomCountFlow) { roomEpoxyController.totalSize = it }
|
listenItemCount(viewModel.roomCountFlow) { roomEpoxyController.totalSize = it }
|
||||||
views.roomList.layoutManager = LinearLayoutManager(context, LinearLayoutManager.VERTICAL, false)
|
views.roomList.layoutManager = LinearLayoutManager(requireContext(), LinearLayoutManager.VERTICAL, false)
|
||||||
views.roomList.setHasFixedSize(true)
|
views.roomList.setHasFixedSize(true)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue