From f6ed0a645a8f06007ffd3b0c81218b2c4b39bf91 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jorge=20Mart=C3=ADn?= Date: Tue, 21 Apr 2026 15:56:38 +0200 Subject: [PATCH 1/5] Add flag for automatic back pagination feature --- .../android/libraries/featureflag/api/FeatureFlags.kt | 8 ++++++++ .../libraries/matrix/impl/RustMatrixClientFactory.kt | 5 +++++ 2 files changed, 13 insertions(+) diff --git a/libraries/featureflag/api/src/main/kotlin/io/element/android/libraries/featureflag/api/FeatureFlags.kt b/libraries/featureflag/api/src/main/kotlin/io/element/android/libraries/featureflag/api/FeatureFlags.kt index c3395d1007..d4e52bdcf6 100644 --- a/libraries/featureflag/api/src/main/kotlin/io/element/android/libraries/featureflag/api/FeatureFlags.kt +++ b/libraries/featureflag/api/src/main/kotlin/io/element/android/libraries/featureflag/api/FeatureFlags.kt @@ -161,4 +161,12 @@ enum class FeatureFlags( defaultValue = { false }, isFinished = false, ), + AutomaticBackPagination( + key = "feature.automatic_back_pagination", + title = "Automatic back pagination of rooms", + description = "Allow the app to automatically back paginate in rooms to pre-fetch older messages in background." + + "\nRequires an app restart to take effect.", + defaultValue = { false }, + isFinished = false, + ), } diff --git a/libraries/matrix/impl/src/main/kotlin/io/element/android/libraries/matrix/impl/RustMatrixClientFactory.kt b/libraries/matrix/impl/src/main/kotlin/io/element/android/libraries/matrix/impl/RustMatrixClientFactory.kt index f83efd2736..6cbf122084 100644 --- a/libraries/matrix/impl/src/main/kotlin/io/element/android/libraries/matrix/impl/RustMatrixClientFactory.kt +++ b/libraries/matrix/impl/src/main/kotlin/io/element/android/libraries/matrix/impl/RustMatrixClientFactory.kt @@ -105,6 +105,11 @@ class RustMatrixClientFactory( suspend fun create(client: Client): RustMatrixClient { val (anonymizedAccessToken, anonymizedRefreshToken) = client.session().anonymizedTokens() + // Must be called before creating the sync service, timelines etc. + if (featureFlagService.isFeatureEnabled(FeatureFlags.AutomaticBackPagination)) { + client.enableAutomaticBackpagination() + } + client.setUtdDelegate(UtdTracker(analyticsService)) val syncService = client.syncService() From 5d270068d62c08de2184665908e1335402562f2d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jorge=20Mart=C3=ADn?= Date: Tue, 21 Apr 2026 16:38:53 +0200 Subject: [PATCH 2/5] Setting version for the release 26.04.4 --- plugins/src/main/kotlin/Versions.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/src/main/kotlin/Versions.kt b/plugins/src/main/kotlin/Versions.kt index 93e92b81ce..d6a2cbea3d 100644 --- a/plugins/src/main/kotlin/Versions.kt +++ b/plugins/src/main/kotlin/Versions.kt @@ -45,7 +45,7 @@ private const val versionMonth = 4 * Release number in the month. Value must be in [0,99]. * Do not update this value. it is updated by the release script. */ -private const val versionReleaseNumber = 3 +private const val versionReleaseNumber = 4 object Versions { /** From d38ef5ba103683946c828d03f9cd6f2a6da22eaf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jorge=20Mart=C3=ADn?= Date: Tue, 21 Apr 2026 16:40:30 +0200 Subject: [PATCH 3/5] Adding fastlane file for version 26.04.4 --- fastlane/metadata/android/en-US/changelogs/202604040.txt | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 fastlane/metadata/android/en-US/changelogs/202604040.txt diff --git a/fastlane/metadata/android/en-US/changelogs/202604040.txt b/fastlane/metadata/android/en-US/changelogs/202604040.txt new file mode 100644 index 0000000000..cbb77b7606 --- /dev/null +++ b/fastlane/metadata/android/en-US/changelogs/202604040.txt @@ -0,0 +1,2 @@ +Main changes in this version: several bug fixes. +Full changelog: https://github.com/element-hq/element-x-android/releases From 0cb1a9fb145ee1879f923ffb50644944584917bc Mon Sep 17 00:00:00 2001 From: ganfra Date: Thu, 7 May 2026 16:01:34 +0200 Subject: [PATCH 4/5] Setting version for the release 26.05.0 --- plugins/src/main/kotlin/Versions.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/src/main/kotlin/Versions.kt b/plugins/src/main/kotlin/Versions.kt index d6a2cbea3d..fa197e4a08 100644 --- a/plugins/src/main/kotlin/Versions.kt +++ b/plugins/src/main/kotlin/Versions.kt @@ -39,13 +39,13 @@ private const val versionYear = 26 * Month of the version on 2 digits. Value must be in [1,12]. * Do not update this value. it is updated by the release script. */ -private const val versionMonth = 4 +private const val versionMonth = 5 /** * Release number in the month. Value must be in [0,99]. * Do not update this value. it is updated by the release script. */ -private const val versionReleaseNumber = 4 +private const val versionReleaseNumber = 0 object Versions { /** From 63edcd69898a7adc4b2008365e718d48fc11a7b2 Mon Sep 17 00:00:00 2001 From: ganfra Date: Thu, 7 May 2026 16:01:40 +0200 Subject: [PATCH 5/5] Adding fastlane file for version 26.05.0 --- fastlane/metadata/android/en-US/changelogs/202605000.txt | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 fastlane/metadata/android/en-US/changelogs/202605000.txt diff --git a/fastlane/metadata/android/en-US/changelogs/202605000.txt b/fastlane/metadata/android/en-US/changelogs/202605000.txt new file mode 100644 index 0000000000..a4b397f1bb --- /dev/null +++ b/fastlane/metadata/android/en-US/changelogs/202605000.txt @@ -0,0 +1,2 @@ +Main changes in this version: bug fixes and improvements. +Full changelog: https://github.com/element-hq/element-x-android/releases \ No newline at end of file