mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-10-10 00:13:08 +02:00
Moves DropDown state to the IO thread.
This commit is contained in:
@@ -1110,6 +1110,7 @@ fun NoteDropDownMenu(note: Note, popupExpanded: Boolean, onDismiss: () -> Unit,
|
|||||||
}
|
}
|
||||||
|
|
||||||
LaunchedEffect(key1 = note) {
|
LaunchedEffect(key1 = note) {
|
||||||
|
withContext(Dispatchers.IO) {
|
||||||
state = DropDownParams(
|
state = DropDownParams(
|
||||||
accountViewModel.isFollowing(note.author),
|
accountViewModel.isFollowing(note.author),
|
||||||
accountViewModel.isInPrivateBookmarks(note),
|
accountViewModel.isInPrivateBookmarks(note),
|
||||||
@@ -1117,6 +1118,7 @@ fun NoteDropDownMenu(note: Note, popupExpanded: Boolean, onDismiss: () -> Unit,
|
|||||||
accountViewModel.isLoggedUser(note.author)
|
accountViewModel.isLoggedUser(note.author)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
DropdownMenu(
|
DropdownMenu(
|
||||||
expanded = popupExpanded,
|
expanded = popupExpanded,
|
||||||
|
Reference in New Issue
Block a user