Skip to content

Instantly share code, notes, and snippets.

View nimaiwalsh's full-sized avatar

Nimai Walsh nimaiwalsh

View GitHub Profile
@iamnaran
iamnaran / AuthNavGraph.kt
Last active July 4, 2024 18:14
Nested Navigation with Multiple Back Stack Android Jetpack Compose
fun NavGraphBuilder.authNavGraph(navController: NavHostController) {
navigation(
startDestination = AppScreen.Auth.Login.route,
route = AppScreen.Auth.route
) {
composable(route = AppScreen.Auth.Login.route) {
LoginScreen(
navigateToHome = {
navController.navigate(AppScreen.Main.route) {
@yusufceylan
yusufceylan / OpenCameraAndSavePhoto.kt
Last active February 6, 2023 03:18
Take photo from camera and save it to gallery
// Take photo from camera and save it to public gallery
// Before Q and After Q implementations
// Answer riginally taken from this SO answer
// https://stackoverflow.com/a/59482148/5695091
private val REQUEST_TAKE_PHOTO = 101
private val REQUEST_PICK_PHOTO = 102
private var photoURI : Uri? = null