1,226 questions
0
votes
1
answer
50
views
Android: How to change the FragmentManager Backstack when going back (insert a new fragment)?
I'm trying to add a view to the fragment stack, without any visible indication that it happened, so it appears when going back.
Forexample,
3 Fragments, A, B and C
A -> C
Then when going BACK from ...
0
votes
1
answer
60
views
Android app crashes on launch: java.lang.ClassNotFoundException for existing Composable screen class
I'm building a Quran app using Jetpack Compose in Kotlin. The app builds successfully and installs on a real Android device (Samsung S908E), but crashes instantly on launch.
Crash Log:
Caused by: java....
0
votes
0
answers
13
views
Responding to fragment navigation changes in androidx.navigation
The documentation for FragmentNavigator says
The current Fragment from FragmentNavigator's perspective can be retrieved by calling FragmentManager.getPrimaryNavigationFragment with the ...
0
votes
0
answers
50
views
Android Compose Navigation out of Scaffold
my Compose app is structured with a Scaffold with its NavHost and BottomNavBar. The scaffold contains three navigation graphs, each of them containing several composables. Navigation can be achieved ...
0
votes
0
answers
40
views
Desparate navigation structure with Official Navigation Library
I'm aiming this scenario:
I have different features like auth with 3 screens, profile with several screens, email with several screens and so on... I want to setup a navigation structure that mainly ...
0
votes
0
answers
68
views
Multiple back stacks without clearing parent back stack (Jetpack Compose)
My project has a bottom bar with tabs A, B and C.
Tab C view has its own navigation C1, C2, C3.
Now if the user navigates e.g. C -> C1 -> C2, than goes to tab B, than back to tab C again, I want ...
2
votes
2
answers
396
views
SafeArgs does not work anymoe after Android Studio update
I have an app that has been working properly for many years and I also installed it on several phones and tablets without any problems. Unfortunately I mad an update of Android Studio (from Flamingo ...
0
votes
1
answer
183
views
Restoring view model state when navigating back
I have a question about how to handle back navigation for a specific situation in my project. The basics look something like this:
I have a tutorial (written all in Compose) that's split into three ...
0
votes
1
answer
26
views
Use navigation or display composable according to account verification state?
I have an app that uses authentication. When a user signs up, the requirement is to verify the account. In my current approach, as soon as the authentication is successful, I navigate the user to the ...
2
votes
0
answers
192
views
Compose NavController is leaking
I add ComposeView straight to activity root (this is how I launch ModalBottomsheetLayout from xml view, example below is simplified but still reproducible)
Here is the whole fragment of reproducible ...
2
votes
0
answers
36
views
Navigating to a top level destination doesn't save all toplevel states
Problem
There are three navigation graphs in my app as nested navigations : HomeGraph, ProfileGraph and MenuGraph. I want to achieve that when you navigate between these graphs through the ...
1
vote
1
answer
45
views
FragmentContainerview animation ordering with popUpTo and popUpToInclusive
This is the setup in the Main Activity:
<androidx.fragment.app.FragmentContainerView
android:id="@+id/nav_host_fragment"
android:name="androidx.navigation....
2
votes
1
answer
108
views
Error "Type mismatch: inferred type is ... but TypeVariable(T) was expected" implementing navigation type safety in Compose NavHost
According to this post, starting with version 2.8.0-alpha08 of Navigation, objects can be used in navigation.
I'm trying to implement it, because I need to pass instances of an object called ItemUI ...
1
vote
2
answers
1k
views
how to pass viewModel as parameter in NavHost compose navigation
I have to following NavHost:
NavHost(
navController = navController,
startDestination = Destinations.ComposeEntryPointRoute
) {
composable<Destinations.HomeRoute> {
HomeContent(...
1
vote
1
answer
141
views
Infinite loop of recomposition if I add an if into a composable
A composable with a navhost is recomposing in an infinite loop if I add an if condition to navigate to a screen if a int parameter representing the current section has been changed. The condition has ...
1
vote
2
answers
239
views
No value passed for parameter 'route'
I am trying to learn app navigation with jetpack compose. I was reading and going through the documentation and code snippets and I came across this code here (Link).
In the documentation, they have ...
1
vote
2
answers
105
views
Issue with androidx.navigation library and slash sign
Issue description:
When I try to create custom navigation type and navigate to certain destination in my NavGraph, I get error, which states, that this certain destination cannot be found in the graph....
2
votes
1
answer
975
views
Typesafe Kotlin DSL NavGraph throws IllegalStateException
I am playing with the new Kotlin DSL Navigation Compose plugin, but I get an exception:
java.lang.IllegalStateException: Cannot find startDestination com.perissf.myapp.SignIn from NavGraph. Ensure ...
1
vote
1
answer
301
views
Check login authentication using ROOM and COMPOSE
My application uses navigation in conjunction with room and compose, my problem is that when starting the app, a check is made in the local database and if the user has selected an option to remember ...
0
votes
0
answers
35
views
how to save fragments using jetpack navigation like other apps do
Jetpack-navigation works well and is responsive in most applications. For example, YouTube: When you go into it you see fragment container and bottom navigation. Inside the fragment container there ...
2
votes
1
answer
652
views
Can I use Shared Element Transition Animation in a Compose with Fragment Navigation
I am currently working on an Android project where I have implemented a FragmentA and a BottomSheetFragmnetB using Jetpack Compose. Both of these fragments utilize traditional Fragment Navigation ...
1
vote
1
answer
50
views
Find an arrow in the fragment of an Android mobile application (Android Studio)
I'm currently developing an Android mobile application in Android Studio for a project aimed at creating an app that centralizes mini-games for playing online or locally. My project is progressing ...
0
votes
1
answer
50
views
No exitAnim and popExitAnim when wrapping NavHostFragment in a AndroidViewBinding
I would like to begin by outlining my current app setup. It utilizes Jetpack Compose and wraps NavController with AndroidViewBinding, enabling me to employ the traditional method of navigation, which ...
0
votes
1
answer
121
views
How to navigate to root Bottom Navigation Menu Item on Android
I'm developing a Android app with Navigation Component with Fragments and a NavGraph.
My app has a BottomNavigationView with Menu Items like described in "Tie destinations to menu items"
...
0
votes
0
answers
23
views
finish() not returning the intent to the previous activity which used startActivityForResult()
I have A, B, C,D as the activity in the current stack.
current stack -> |A|
I have launched B from A using startActivityForResult()
current stack -> |B|
|A|
Now inside of B I ...