Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Android Composeでの自動入力(作成:GPT-4o)
Search
tonionagauzzi
April 24, 2025
Programming
180
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Android Composeでの自動入力(作成:GPT-4o)
tonionagauzzi
April 24, 2025
More Decks by tonionagauzzi
See All by tonionagauzzi
Androidエンジニアが大規模プロダクトのWebフロントエンドとバックエンドに越境して感じたギャップと習得したマインド
tonionagauzzi
0
460
Kotlin2.3明示的バッキングフィールド
tonionagauzzi
1
410
【Android】テキスト選択色の問題修正で心がけたこと
tonionagauzzi
0
290
Android 15以上でPDFのテキスト検索を爆速開発!
tonionagauzzi
0
420
Googleの新しいコーディングAIエージェントJulesを使ってみた
tonionagauzzi
0
880
Compose におけるパスワード自動入力とパスワード保存
tonionagauzzi
0
560
Androidテスト基礎講義
tonionagauzzi
0
420
Jetpack Composeで自動入力(Autofill)を実装しよう(作成:claude-3.7-sonnet)
tonionagauzzi
0
180
Jetpack Composeにおける自動入力の実装と注意点(作成者:Gemini 2.5 Pro Exp 03-25)
tonionagauzzi
0
190
Other Decks in Programming
See All in Programming
半永久的に提供し続けられるプライベートクラウドを目指して ― 利用者の認知負荷を抑えるAPI抽象化とハードウェア世代交代の基盤設計
tomokon
0
440
R8 の設定見直しでアプリサイズ削減
andpad
0
140
[ハンズオン]AIへの指示だけで「五目並べ」を作ってみよう
satoshi256kbyte
1
340
Augmenting AI with the Power of Jakarta EE
ivargrimstad
0
520
iOS 27でニュースアプリはどう変わる!? 〜日経電子版の新機能対応と、開発事例から〜
lynnswap
7
13k
機械に任せるテスト、人が見るテスト ⽣成AIで引き直した、運⽤保守フェーズの線引き
dske104
0
160
プロダクトコードからライブラリの境界を見つける
elmetal
PRO
0
100
Turning Architecture into Unit Tests in the AI Era (NSSpain XIV)
steliosf
PRO
1
130
Androidだけじゃない、DroidKaigiで広がった私の技術スタック
akkeylab
0
120
速習iPhone Duo対応
yuukiw00w
2
960
ソニーのクラウド共通基盤の変遷とAI時代の開発スタイルに合わせた進化 / The Journey of Sony’s Common Cloud Platform and Its Evolution for AI-Native Development
kenjiyoneyama
0
230
JAWS-UG 東京支部が始める、JAWS-UG支部コラボ / JAWS-UG lunchtime LT Collaboration
y0hgi
0
180
Featured
See All Featured
Navigating Team Friction
lara
192
16k
From π to Pie charts
rasagy
1
390
Leo the Paperboy
mayatellez
10
2.3k
Producing Creativity
orderedlist
PRO
348
41k
Joys of Absence: A Defence of Solitary Play
codingconduct
1
530
Introduction to Domain-Driven Design and Collaborative software design
baasie
1
1k
Bash Introduction
62gerente
615
220k
Done Done
chrislema
187
17k
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Color Theory Basics | Prateek | Gurzu
gurzu
1
480
The browser strikes back
jonoalderson
0
1.8k
Transcript
Android Composeでの自動入力 Jetpack Composeでの自動入力の有効化方法 ハマりどころと解決策 1
自動入力とは? パスワード入力欄にカーソルを当てると保存済みもしくは生成したパスワードを 自動で入力 従来のXML型Android Viewでは android:autofillHints プロパティを使用 2
Jetpack Composeでの自動入力 Compose UIを1.8.0以降にアップデート Modifier.semantics を使用して contentType を指定 Column {
TextField( value = username.value, onValueChange = {username.value = it}, modifier = Modifier.semantics { contentType = ContentType.Username } ) TextField( value = password.value, onValueChange = {password.value = it}, modifier = Modifier.semantics { contentType = ContentType.Password } ) } 3
ハマりどころ autofillManager?.commit() が動作しない場合 NewUsername と NewPassword の両方が1つのComposable内にある必要 4
解決策 CredentialManager を使用 androidx.credentials をインポート Column { val context =
LocalContext.current val coroutineScope = rememberCoroutineScope() TextField( value = newPassword.value, onValueChange = { newPassword.value = it }, modifier = Modifier.semantics { contentType = ContentType.NewPassword }, ) Button(onClick = { try { coroutineScope.launch { val credentialManager = CredentialManager.create(context) val request = CreatePasswordRequest(username, newPassword.value) credentialManager.createCredential( request = request, context = context, ) } } catch (e: CreateCredentialException) { 5
まとめ Jetpack Composeでの自動入力の有効化は簡単 CredentialManager を使うことで問題を回避可能 6
参考文献 Jetpack Composeでandroid:autofillHintsのような自動入力を有効にするには? Jetpack ComposeのTextFieldに入力されたパスワードを保存するには? 7