mirror of
https://github.com/Novaloop-AG/element-x-android.git
synced 2026-11-03 16:10:00 +00:00
Merge pull request #7194 from element-hq/renovate/org.matrix.rustcomponents-sdk-android-26.x
Update dependency org.matrix.rustcomponents:sdk-android to v26.07.13
This commit is contained in:
@@ -185,7 +185,7 @@ test_detekt_test = { module = "io.gitlab.arturbosch.detekt:detekt-test", version
|
|||||||
# https://github.com/matrix-org/matrix-rust-components-kotlin/commits/main/sdk/sdk-android/src/main/kotlin/org/matrix/rustcomponents/sdk/matrix_sdk_ffi.kt
|
# https://github.com/matrix-org/matrix-rust-components-kotlin/commits/main/sdk/sdk-android/src/main/kotlin/org/matrix/rustcomponents/sdk/matrix_sdk_ffi.kt
|
||||||
# All new features should not be implemented in the pull request that upgrades the version, developers should
|
# All new features should not be implemented in the pull request that upgrades the version, developers should
|
||||||
# only fix API breaks and may add some TODOs.
|
# only fix API breaks and may add some TODOs.
|
||||||
matrix_sdk = "org.matrix.rustcomponents:sdk-android:26.06.30"
|
matrix_sdk = "org.matrix.rustcomponents:sdk-android:26.07.13"
|
||||||
|
|
||||||
# Others
|
# Others
|
||||||
coil = { module = "io.coil-kt.coil3:coil", version.ref = "coil" }
|
coil = { module = "io.coil-kt.coil3:coil", version.ref = "coil" }
|
||||||
|
|||||||
+3
@@ -89,6 +89,8 @@ sealed interface NotificationContent {
|
|||||||
val senderId: UserId,
|
val senderId: UserId,
|
||||||
val question: String,
|
val question: String,
|
||||||
) : MessageLike
|
) : MessageLike
|
||||||
|
|
||||||
|
data object Beacon : MessageLike
|
||||||
}
|
}
|
||||||
|
|
||||||
sealed interface StateEvent : NotificationContent {
|
sealed interface StateEvent : NotificationContent {
|
||||||
@@ -116,6 +118,7 @@ sealed interface NotificationContent {
|
|||||||
data class RoomTopic(val topic: String) : StateEvent
|
data class RoomTopic(val topic: String) : StateEvent
|
||||||
data object SpaceChild : StateEvent
|
data object SpaceChild : StateEvent
|
||||||
data object SpaceParent : StateEvent
|
data object SpaceParent : StateEvent
|
||||||
|
data object BeaconInfo : StateEvent
|
||||||
}
|
}
|
||||||
|
|
||||||
data class Invite(
|
data class Invite(
|
||||||
|
|||||||
+2
@@ -71,6 +71,7 @@ private fun StateEventContent.toContent(): NotificationContent.StateEvent {
|
|||||||
is StateEventContent.RoomTopic -> NotificationContent.StateEvent.RoomTopic(topic)
|
is StateEventContent.RoomTopic -> NotificationContent.StateEvent.RoomTopic(topic)
|
||||||
StateEventContent.SpaceChild -> NotificationContent.StateEvent.SpaceChild
|
StateEventContent.SpaceChild -> NotificationContent.StateEvent.SpaceChild
|
||||||
StateEventContent.SpaceParent -> NotificationContent.StateEvent.SpaceParent
|
StateEventContent.SpaceParent -> NotificationContent.StateEvent.SpaceParent
|
||||||
|
StateEventContent.BeaconInfo -> NotificationContent.StateEvent.BeaconInfo
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -108,6 +109,7 @@ private fun MessageLikeEventContent.toContent(senderId: UserId): NotificationCon
|
|||||||
)
|
)
|
||||||
MessageLikeEventContent.Sticker -> NotificationContent.MessageLike.Sticker
|
MessageLikeEventContent.Sticker -> NotificationContent.MessageLike.Sticker
|
||||||
is MessageLikeEventContent.Poll -> NotificationContent.MessageLike.Poll(senderId, question)
|
is MessageLikeEventContent.Poll -> NotificationContent.MessageLike.Poll(senderId, question)
|
||||||
|
MessageLikeEventContent.Beacon -> NotificationContent.MessageLike.Beacon
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+2
@@ -90,6 +90,8 @@ class RustMatrixClientTest {
|
|||||||
userId = userId,
|
userId = userId,
|
||||||
displayName = A_USER_NAME,
|
displayName = A_USER_NAME,
|
||||||
avatarUrl = AN_AVATAR_URL,
|
avatarUrl = AN_AVATAR_URL,
|
||||||
|
status = null,
|
||||||
|
call = null,
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
|||||||
+6
@@ -9,14 +9,20 @@
|
|||||||
package io.element.android.libraries.matrix.impl.fixtures.factories
|
package io.element.android.libraries.matrix.impl.fixtures.factories
|
||||||
|
|
||||||
import io.element.android.libraries.matrix.test.A_USER_ID
|
import io.element.android.libraries.matrix.test.A_USER_ID
|
||||||
|
import org.matrix.rustcomponents.sdk.UserCall
|
||||||
import org.matrix.rustcomponents.sdk.UserProfile
|
import org.matrix.rustcomponents.sdk.UserProfile
|
||||||
|
import org.matrix.rustcomponents.sdk.UserStatus
|
||||||
|
|
||||||
internal fun aRustUserProfile(
|
internal fun aRustUserProfile(
|
||||||
userId: String = A_USER_ID.value,
|
userId: String = A_USER_ID.value,
|
||||||
displayName: String = "displayName",
|
displayName: String = "displayName",
|
||||||
avatarUrl: String = "avatarUrl",
|
avatarUrl: String = "avatarUrl",
|
||||||
|
status: UserStatus? = null,
|
||||||
|
call: UserCall? = null,
|
||||||
) = UserProfile(
|
) = UserProfile(
|
||||||
userId = userId,
|
userId = userId,
|
||||||
displayName = displayName,
|
displayName = displayName,
|
||||||
avatarUrl = avatarUrl,
|
avatarUrl = avatarUrl,
|
||||||
|
status = status,
|
||||||
|
call = call,
|
||||||
)
|
)
|
||||||
|
|||||||
+2
-1
@@ -9,6 +9,7 @@
|
|||||||
package io.element.android.libraries.matrix.impl.fixtures.fakes
|
package io.element.android.libraries.matrix.impl.fixtures.fakes
|
||||||
|
|
||||||
import io.element.android.libraries.matrix.impl.fixtures.factories.aRustSession
|
import io.element.android.libraries.matrix.impl.fixtures.factories.aRustSession
|
||||||
|
import io.element.android.libraries.matrix.impl.fixtures.factories.aRustUserProfile
|
||||||
import io.element.android.libraries.matrix.test.A_DEVICE_ID
|
import io.element.android.libraries.matrix.test.A_DEVICE_ID
|
||||||
import io.element.android.libraries.matrix.test.A_HOMESERVER_URL
|
import io.element.android.libraries.matrix.test.A_HOMESERVER_URL
|
||||||
import io.element.android.libraries.matrix.test.A_USER_ID
|
import io.element.android.libraries.matrix.test.A_USER_ID
|
||||||
@@ -49,7 +50,7 @@ class FakeFfiClient(
|
|||||||
private val session: Session = aRustSession(),
|
private val session: Session = aRustSession(),
|
||||||
private val clearCachesResult: () -> Unit = { lambdaError() },
|
private val clearCachesResult: () -> Unit = { lambdaError() },
|
||||||
private val withUtdHook: (UnableToDecryptDelegate) -> Unit = { lambdaError() },
|
private val withUtdHook: (UnableToDecryptDelegate) -> Unit = { lambdaError() },
|
||||||
private val getProfileResult: (String) -> UserProfile = { UserProfile(userId = userId, displayName = null, avatarUrl = null) },
|
private val getProfileResult: (String) -> UserProfile = { aRustUserProfile() },
|
||||||
private val homeserverLoginDetailsResult: () -> HomeserverLoginDetails = { lambdaError() },
|
private val homeserverLoginDetailsResult: () -> HomeserverLoginDetails = { lambdaError() },
|
||||||
private val getStoreSizesResult: () -> StoreSizes = { lambdaError() },
|
private val getStoreSizesResult: () -> StoreSizes = { lambdaError() },
|
||||||
private val createRoomResult: (CreateRoomParameters) -> String = { lambdaError() },
|
private val createRoomResult: (CreateRoomParameters) -> String = { lambdaError() },
|
||||||
|
|||||||
+6
-1
@@ -299,6 +299,10 @@ class DefaultNotifiableEventResolver(
|
|||||||
Timber.tag(loggerTag.value).d("Ignoring notification for sticker")
|
Timber.tag(loggerTag.value).d("Ignoring notification for sticker")
|
||||||
throw NotificationResolverException.EventFilteredOut
|
throw NotificationResolverException.EventFilteredOut
|
||||||
}
|
}
|
||||||
|
NotificationContent.MessageLike.Beacon -> {
|
||||||
|
Timber.tag(loggerTag.value).d("Ignoring notification for beacon")
|
||||||
|
throw NotificationResolverException.EventFilteredOut
|
||||||
|
}
|
||||||
is NotificationContent.StateEvent.RoomMemberContent,
|
is NotificationContent.StateEvent.RoomMemberContent,
|
||||||
NotificationContent.StateEvent.PolicyRuleRoom,
|
NotificationContent.StateEvent.PolicyRuleRoom,
|
||||||
NotificationContent.StateEvent.PolicyRuleServer,
|
NotificationContent.StateEvent.PolicyRuleServer,
|
||||||
@@ -318,7 +322,8 @@ class DefaultNotifiableEventResolver(
|
|||||||
NotificationContent.StateEvent.RoomTombstone,
|
NotificationContent.StateEvent.RoomTombstone,
|
||||||
is NotificationContent.StateEvent.RoomTopic,
|
is NotificationContent.StateEvent.RoomTopic,
|
||||||
NotificationContent.StateEvent.SpaceChild,
|
NotificationContent.StateEvent.SpaceChild,
|
||||||
NotificationContent.StateEvent.SpaceParent -> {
|
NotificationContent.StateEvent.SpaceParent,
|
||||||
|
NotificationContent.StateEvent.BeaconInfo -> {
|
||||||
Timber.tag(loggerTag.value).d("Ignoring notification for state event ${content.javaClass.simpleName}")
|
Timber.tag(loggerTag.value).d("Ignoring notification for state event ${content.javaClass.simpleName}")
|
||||||
throw NotificationResolverException.EventFilteredOut
|
throw NotificationResolverException.EventFilteredOut
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user