Skip to content
Merged
Show file tree
Hide file tree
Changes from 24 commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
8a9a699
Set compileSdk and targetSdk to 35
bmarty Jul 7, 2025
a283eea
Fix compilation issue.
bmarty Jul 7, 2025
3652ae5
Upgrade Android Gradle Plugin to 8.11.0
bmarty Jul 8, 2025
390ae56
Update gradle wraaper using command line
bmarty Jul 8, 2025
da983b4
Update lint version
bmarty Jul 8, 2025
06721da
Update gradle wraaper using command line
bmarty Jul 8, 2025
78e100d
Supress deprecation warning.
bmarty Jul 8, 2025
6e56c38
Fix lint warning
bmarty Jul 9, 2025
27fc09b
Fix lint warning
bmarty Jul 9, 2025
cf01890
Fix lint warning: ignore impossible SecurityException
bmarty Jul 9, 2025
de3874e
Fix lint warning: check permission before notifying with notification
bmarty Jul 11, 2025
fd67cac
Fix lint warning: check permission before using location API
bmarty Jul 11, 2025
e562208
Fix lint warning: check permission before recording audio
bmarty Jul 11, 2025
1d08018
A final period.
bmarty Jul 11, 2025
9b0d22f
Avoid crash for long logs.
bmarty Jul 15, 2025
3d7bf51
Target API 35: set `android:fitsSystemWindows="true"` to Activities.
bmarty Jul 15, 2025
0a69a33
Remove dead code.
bmarty Jul 15, 2025
58de848
Fix UI issue
bmarty Jul 15, 2025
66ec110
Remove useless margin
bmarty Jul 15, 2025
82317bf
Fix color issue on HomeActivity and RoomDetailActivity (others do not…
bmarty Jul 15, 2025
3f22ddb
Fix regression on timeline for thread.
bmarty Jul 16, 2025
daadbbd
Revert "Target API 35: set `android:fitsSystemWindows="true"` to Acti…
bmarty Jul 16, 2025
c79f2ff
Enable edgeToEdge
bmarty Jul 16, 2025
89b1034
Fix issue in timeline screen.
bmarty Jul 16, 2025
f421ead
Code cleanup
bmarty Jul 16, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions dependencies.gradle
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
ext.versions = [
'minSdk' : 21,
'compileSdk' : 34,
'targetSdk' : 34,
'compileSdk' : 35,
'targetSdk' : 35,
'sourceCompat' : JavaVersion.VERSION_21,
'targetCompat' : JavaVersion.VERSION_21,
'jvmTarget' : "21",
]

def gradle = "8.4.2"
def gradle = "8.11.0"
// Ref: https://kotlinlang.org/releases.html
def kotlin = "1.9.24"
def kotlinCoroutines = "1.8.1"
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@ signing.element.nightly.keyPassword=Secret

# Customise the Lint version to use a more recent version than the one bundled with AGP
# https://googlesamples.github.io/android-custom-lint-rules/usage/newer-lint.md.html
android.experimental.lint.version=8.6.0-alpha08
android.experimental.lint.version=8.12.0-alpha08
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
4 changes: 2 additions & 2 deletions gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionSha256Sum=f8b4f4772d302c8ff580bc40d0f56e715de69b163546944f787c87abf209c961
distributionUrl=https\://services.gradle.org/distributions/gradle-8.8-all.zip
distributionSha256Sum=bd71102213493060956ec229d946beee57158dbd89d0e62b91bca0fa2c5f3531
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
37 changes: 22 additions & 15 deletions gradlew

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

26 changes: 14 additions & 12 deletions gradlew.bat

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -131,12 +131,15 @@ abstract class AttachmentViewerActivity : AppCompatActivity(), AttachmentEventLi
// the touch coordinates
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) {
// New API instead of SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN and SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
@Suppress("DEPRECATION")
window.setDecorFitsSystemWindows(false)
// New API instead of SYSTEM_UI_FLAG_IMMERSIVE
window.decorView.windowInsetsController?.systemBarsBehavior = WindowInsetsController.BEHAVIOR_SHOW_TRANSIENT_BARS_BY_SWIPE
// New API instead of FLAG_TRANSLUCENT_STATUS
@Suppress("DEPRECATION")
window.statusBarColor = ContextCompat.getColor(this, R.color.half_transparent_status_bar)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At some point we should move these colors to enableEdgeToEdge I think. We can probably wait until it's mandatory though.

// new API instead of FLAG_TRANSLUCENT_NAVIGATION
@Suppress("DEPRECATION")
window.navigationBarColor = ContextCompat.getColor(this, R.color.half_transparent_status_bar)
} else {
@Suppress("DEPRECATION")
Expand Down Expand Up @@ -318,6 +321,7 @@ abstract class AttachmentViewerActivity : AppCompatActivity(), AttachmentEventLi
protected open fun shouldAnimateDismiss(): Boolean = true

protected open fun animateClose() {
@Suppress("DEPRECATION")
window.statusBarColor = Color.TRANSPARENT
finish()
}
Expand All @@ -334,14 +338,17 @@ abstract class AttachmentViewerActivity : AppCompatActivity(), AttachmentEventLi
// Or for "sticky immersive," replace it with SYSTEM_UI_FLAG_IMMERSIVE_STICKY
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) {
// New API instead of SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN and SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
@Suppress("DEPRECATION")
window.setDecorFitsSystemWindows(false)
// new API instead of SYSTEM_UI_FLAG_HIDE_NAVIGATION
window.decorView.windowInsetsController?.hide(WindowInsets.Type.navigationBars())
// New API instead of SYSTEM_UI_FLAG_IMMERSIVE
window.decorView.windowInsetsController?.systemBarsBehavior = WindowInsetsController.BEHAVIOR_SHOW_TRANSIENT_BARS_BY_SWIPE
// New API instead of FLAG_TRANSLUCENT_STATUS
@Suppress("DEPRECATION")
window.statusBarColor = ContextCompat.getColor(this, R.color.half_transparent_status_bar)
// New API instead of FLAG_TRANSLUCENT_NAVIGATION
@Suppress("DEPRECATION")
window.navigationBarColor = ContextCompat.getColor(this, R.color.half_transparent_status_bar)
} else {
@Suppress("DEPRECATION")
Expand All @@ -363,6 +370,7 @@ abstract class AttachmentViewerActivity : AppCompatActivity(), AttachmentEventLi
systemUiVisibility = true
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) {
// New API instead of SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN and SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION
@Suppress("DEPRECATION")
window.setDecorFitsSystemWindows(false)
} else {
@Suppress("DEPRECATION")
Expand Down
3 changes: 3 additions & 0 deletions library/ui-styles/src/main/res/values/theme_light.xml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@

<!-- Material color -->
<item name="colorPrimary">@color/element_accent_light</item>
<!-- Fix background color of status bar in home and room detail activity -->
<!--item name="colorPrimaryDark">@color/element_background_light</item-->
<item name="colorPrimaryDark">?vctr_toolbar_background</item>
<item name="colorPrimaryVariant">@color/element_accent_light</item>
<item name="colorOnPrimary">@android:color/white</item>
<item name="colorSecondary">@color/element_accent_light</item>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ internal class FormattedJsonHttpLogger(
*/
@Synchronized
override fun log(message: String) {
Timber.v(message)
Timber.v(message.take(20_000))
if (message.length > 20_000) return

// Try to log formatted Json only if there is a chance that [message] contains Json.
// It can be only the case if we log the bodies of Http requests.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import android.app.NotificationChannel
import android.app.NotificationManager
import android.content.Intent
import android.os.Build
import android.view.View
import androidx.core.app.NotificationCompat
import androidx.core.app.Person
import androidx.core.content.getSystemService
Expand Down Expand Up @@ -49,7 +50,9 @@ import javax.inject.Inject
class DebugMenuActivity : VectorBaseActivity<ActivityDebugMenuBinding>() {

override fun getBinding() = ActivityDebugMenuBinding.inflate(layoutInflater)

override fun getCoordinatorLayout() = views.coordinatorLayout
override val rootView: View
get() = views.coordinatorLayout
@Inject lateinit var clock: Clock

private lateinit var buffer: ByteArray
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ package im.vector.app.features.debug
import android.Manifest
import android.content.pm.PackageManager
import android.os.Build
import android.view.View
import android.widget.Toast
import androidx.core.app.ActivityCompat
import androidx.core.content.ContextCompat
Expand All @@ -32,6 +33,9 @@ class DebugPermissionActivity : VectorBaseActivity<ActivityDebugPermissionBindin

override fun getCoordinatorLayout() = views.coordinatorLayout

override val rootView: View
get() = views.coordinatorLayout

// For debug
private val allPermissions = listOf(
Manifest.permission.CAMERA,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

package im.vector.app.features.debug.analytics

import android.view.View
import dagger.hilt.android.AndroidEntryPoint
import im.vector.app.core.extensions.addFragment
import im.vector.app.core.platform.VectorBaseActivity
Expand All @@ -17,6 +18,10 @@ class DebugAnalyticsActivity : VectorBaseActivity<ActivitySimpleBinding>() {

override fun getBinding() = ActivitySimpleBinding.inflate(layoutInflater)

override fun getCoordinatorLayout() = views.coordinatorLayout
override val rootView: View
get() = views.coordinatorLayout

override fun initUiAndData() {
if (isFirstCreation()) {
addFragment(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
package im.vector.app.features.debug.features

import android.os.Bundle
import android.view.View
import dagger.hilt.android.AndroidEntryPoint
import im.vector.app.core.extensions.cleanup
import im.vector.app.core.extensions.configureWith
Expand All @@ -24,6 +25,9 @@ class DebugFeaturesSettingsActivity : VectorBaseActivity<FragmentGenericRecycler

override fun getBinding() = FragmentGenericRecyclerBinding.inflate(layoutInflater)

override val rootView: View
get() = views.mainRoot

override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
controller.listener = object : FeaturesController.Listener {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
package im.vector.app.features.debug.jitsi

import android.annotation.SuppressLint
import android.view.View
import dagger.hilt.android.AndroidEntryPoint
import im.vector.app.core.platform.VectorBaseActivity
import im.vector.application.databinding.ActivityDebugJitsiBinding
Expand All @@ -19,6 +20,8 @@ class DebugJitsiActivity : VectorBaseActivity<ActivityDebugJitsiBinding>() {
override fun getBinding() = ActivityDebugJitsiBinding.inflate(layoutInflater)

override fun getCoordinatorLayout() = views.coordinatorLayout
override val rootView: View
get() = views.coordinatorLayout

@SuppressLint("SetTextI18n")
override fun initUiAndData() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

package im.vector.app.features.debug.leak

import android.view.View
import dagger.hilt.android.AndroidEntryPoint
import im.vector.app.core.extensions.addFragment
import im.vector.app.core.platform.VectorBaseActivity
Expand All @@ -17,6 +18,10 @@ class DebugMemoryLeaksActivity : VectorBaseActivity<ActivitySimpleBinding>() {

override fun getBinding() = ActivitySimpleBinding.inflate(layoutInflater)

override fun getCoordinatorLayout() = views.coordinatorLayout
override val rootView: View
get() = views.coordinatorLayout

override fun initUiAndData() {
if (isFirstCreation()) {
addFragment(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

package im.vector.app.features.debug.settings

import android.view.View
import dagger.hilt.android.AndroidEntryPoint
import im.vector.app.core.extensions.addFragment
import im.vector.app.core.platform.VectorBaseActivity
Expand All @@ -17,6 +18,10 @@ class DebugPrivateSettingsActivity : VectorBaseActivity<ActivitySimpleBinding>()

override fun getBinding() = ActivitySimpleBinding.inflate(layoutInflater)

override fun getCoordinatorLayout() = views.coordinatorLayout
override val rootView: View
get() = views.coordinatorLayout

override fun initUiAndData() {
if (isFirstCreation()) {
addFragment(
Expand Down
Loading
Loading