[PR #7] [CLOSED] Bump deps, replace deprecated APIs, and refactoring oh my #46

Closed
opened 2026-02-16 12:26:43 -05:00 by yindo · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/stoatchat/for-android/pull/7
Author: @Pi-Cla
Created: 11/20/2024
Status: Closed

Base: devHead: bump-deps


📝 Commits (2)

  • 61a7b87 chore: bump gradle deps
  • d2b0859 chore: replace deprecated APIs and minor refactoring

📊 Changes

23 files changed (+518 additions, -517 deletions)

View changed files

📝 app/build.gradle.kts (+25 -27)
📝 app/src/main/java/chat/revolt/activities/InviteActivity.kt (+0 -2)
📝 app/src/main/java/chat/revolt/activities/MainActivity.kt (+0 -4)
📝 app/src/main/java/chat/revolt/activities/media/ImageViewActivity.kt (+2 -2)
📝 app/src/main/java/chat/revolt/activities/media/VideoViewActivity.kt (+2 -2)
📝 app/src/main/java/chat/revolt/api/RevoltAPI.kt (+2 -2)
📝 app/src/main/java/chat/revolt/components/chat/NativeMessageField.kt (+8 -4)
📝 app/src/main/java/chat/revolt/components/markdown/jbm/JBMRenderer.kt (+2 -2)
📝 app/src/main/java/chat/revolt/components/media/AudioPlayer.kt (+2 -2)
📝 app/src/main/java/chat/revolt/components/screens/settings/appearance/CornerRadiusPicker.kt (+2 -1)
📝 app/src/main/java/chat/revolt/components/utils/Lifecycle.kt (+1 -1)
📝 app/src/main/java/chat/revolt/internals/Autocomplete.kt (+2 -2)
📝 app/src/main/java/chat/revolt/providers/AttachmentProvider.kt (+2 -2)
📝 app/src/main/java/chat/revolt/screens/DefaultDestinationScreen.kt (+0 -3)
📝 app/src/main/java/chat/revolt/screens/chat/dialogs/safety/ReportMessageDialog.kt (+2 -1)
📝 app/src/main/java/chat/revolt/screens/chat/dialogs/safety/ReportServerDialog.kt (+2 -1)
📝 app/src/main/java/chat/revolt/screens/chat/dialogs/safety/ReportUserDialog.kt (+2 -1)
📝 app/src/main/java/chat/revolt/screens/chat/views/channel/ChannelScreen.kt (+429 -425)
📝 app/src/main/java/chat/revolt/screens/chat/views/channel/ChannelScreenViewModel.kt (+15 -8)
📝 app/src/main/java/chat/revolt/screens/settings/ChangelogsScreen.kt (+2 -2)

...and 3 more files

📄 Description

setStatusBarColor is being deprecated and API 35 already sets the color to transparent so just stop setting the color
https://developer.android.com/reference/android/view/Window?hl=en#setStatusBarColor(int)

Use animateItem instead of deprecated animeItemPlacement
https://developer.android.com/jetpack/androidx/releases/compose-animation#1.7.0-alpha06

LocalLifecycleOwner is moved to androidx.lifecycle.compose
https://developer.android.com/reference/kotlin/androidx/compose/ui/platform/package-summary#LocalLifecycleOwner()

Use mutableFloatStateOf rather than mutableStateOf when checking floats

Rewrite if if-else chains into when statements

Remove redundant suspends

  • I understand and have followed the contribution guide
  • I have tested my changes locally and they are working as intended

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/stoatchat/for-android/pull/7 **Author:** [@Pi-Cla](https://github.com/Pi-Cla) **Created:** 11/20/2024 **Status:** ❌ Closed **Base:** `dev` ← **Head:** `bump-deps` --- ### 📝 Commits (2) - [`61a7b87`](https://github.com/stoatchat/for-android/commit/61a7b87c7612016e34ecc47793cb595df3ddd56d) chore: bump gradle deps - [`d2b0859`](https://github.com/stoatchat/for-android/commit/d2b0859aa1834df579bb7fad41242930df7c666b) chore: replace deprecated APIs and minor refactoring ### 📊 Changes **23 files changed** (+518 additions, -517 deletions) <details> <summary>View changed files</summary> 📝 `app/build.gradle.kts` (+25 -27) 📝 `app/src/main/java/chat/revolt/activities/InviteActivity.kt` (+0 -2) 📝 `app/src/main/java/chat/revolt/activities/MainActivity.kt` (+0 -4) 📝 `app/src/main/java/chat/revolt/activities/media/ImageViewActivity.kt` (+2 -2) 📝 `app/src/main/java/chat/revolt/activities/media/VideoViewActivity.kt` (+2 -2) 📝 `app/src/main/java/chat/revolt/api/RevoltAPI.kt` (+2 -2) 📝 `app/src/main/java/chat/revolt/components/chat/NativeMessageField.kt` (+8 -4) 📝 `app/src/main/java/chat/revolt/components/markdown/jbm/JBMRenderer.kt` (+2 -2) 📝 `app/src/main/java/chat/revolt/components/media/AudioPlayer.kt` (+2 -2) 📝 `app/src/main/java/chat/revolt/components/screens/settings/appearance/CornerRadiusPicker.kt` (+2 -1) 📝 `app/src/main/java/chat/revolt/components/utils/Lifecycle.kt` (+1 -1) 📝 `app/src/main/java/chat/revolt/internals/Autocomplete.kt` (+2 -2) 📝 `app/src/main/java/chat/revolt/providers/AttachmentProvider.kt` (+2 -2) 📝 `app/src/main/java/chat/revolt/screens/DefaultDestinationScreen.kt` (+0 -3) 📝 `app/src/main/java/chat/revolt/screens/chat/dialogs/safety/ReportMessageDialog.kt` (+2 -1) 📝 `app/src/main/java/chat/revolt/screens/chat/dialogs/safety/ReportServerDialog.kt` (+2 -1) 📝 `app/src/main/java/chat/revolt/screens/chat/dialogs/safety/ReportUserDialog.kt` (+2 -1) 📝 `app/src/main/java/chat/revolt/screens/chat/views/channel/ChannelScreen.kt` (+429 -425) 📝 `app/src/main/java/chat/revolt/screens/chat/views/channel/ChannelScreenViewModel.kt` (+15 -8) 📝 `app/src/main/java/chat/revolt/screens/settings/ChangelogsScreen.kt` (+2 -2) _...and 3 more files_ </details> ### 📄 Description setStatusBarColor is being deprecated and API 35 already sets the color to transparent so just stop setting the color https://developer.android.com/reference/android/view/Window?hl=en#setStatusBarColor(int) Use animateItem instead of deprecated animeItemPlacement https://developer.android.com/jetpack/androidx/releases/compose-animation#1.7.0-alpha06 LocalLifecycleOwner is moved to androidx.lifecycle.compose https://developer.android.com/reference/kotlin/androidx/compose/ui/platform/package-summary#LocalLifecycleOwner() Use mutableFloatStateOf rather than mutableStateOf when checking floats Rewrite if if-else chains into when statements Remove redundant suspends - [x] I understand and have followed the [contribution guide](https://github.com/revoltchat/.github/blob/master/.github/CONTRIBUTING.md) - [x] I have tested my changes locally and they are working as intended --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
yindo added the pull-request label 2026-02-16 12:26:43 -05:00
yindo closed this issue 2026-02-16 12:26:44 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: stoatchat/for-android#46