일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 | 31 |
Tags
- InputTypes
- Android
- 안드로이드
- cocoapods
- 액티비티
- ImageView
- ios
- linearlayout
- 앱빌드
- Constraint
- Lottie
- 프래그먼트
- EditText
- 프로젝트생성
- Drawable
- 리소스
- 화면전환
- lateInit
- kotlin
- 스택관리
- DataBinding
- 데이터바인딩
- LayoutEditor
- 코틀린
- API Level
- gradle
- 코코아팟
- xcworkspace
- SWIFT
- button
Archives
- Today
- Total
코코아의 우당탕탕 개발일지
[Android/Kotlin] 안드로이드 학습 3.3 - 외부 활동 본문
학습과정 3번에서의 게임 결과를 다른 앱으로 보내고 친구와 공유해보자.
Android Kotlin Fundamentals: 03.3 Start an external Activity | Android Developers
In this codelab, you learn how to pass parameters to a Fragment using safe args to make debugging your app easier, and how to invoke an external Activity in an app.
developer.android.com
Bundle
- key - value 형태의 저장소.
- directory 또는 associative array라고도 불림
- 고유 키(문자열)를 사용하여 해당 키와 관련된 값을 가져오는 데이터 구조
- Bundle를 활용해 Fragment끼리 데이터를 전달받을 수 있음
1. 프로젝트에 Safe Args 추가
build.gradle(Project)에서 종속성 추가
classpath "androidx.navigation:navigation-safe-args-gradle-plugin:$navigationVersion"
build.gradle(Module)에서
apply plugin: 'androidx.navigation.safeargs'
'[Android] > 학습' 카테고리의 다른 글
[Android/Kotlin] 안드로이드 학습 5.1 - ViewModel & ViewModelProvider (0) | 2022.12.13 |
---|---|
[Android/Kotlin] 안드로이드 학습 4 - 생명주기(Life Cycle) (0) | 2022.11.09 |
[Android/Kotlin] 안드로이드 학습 3.2 - 네비게이션 (0) | 2022.11.09 |
[Android/Kotlin] 안드로이드 학습 3.1 - Fragment 만들기 (0) | 2022.11.05 |
[Android/Kotlin] 학습과정 5.1 - ViewModel (0) | 2022.11.02 |