Merge pull request #2421 from anayw2001/main

Update Android documentation
This commit is contained in:
Anay Wadhera
2024-04-10 15:16:15 -04:00
committed by GitHub
3 changed files with 92 additions and 4 deletions
@@ -72,10 +72,22 @@ class MainActivity : ComponentActivity() {
onShareTargetClicked = { data, intent ->
viewModel.onShareTargetClicked(data, this@MainActivity, intent)
})
Button(onClick = { startActivity(Intent(QUICK_SHARE_SETTINGS_INTENT)) }) {
Text("Launch settings")
}
Button(onClick = { startActivity(Intent(QUICK_SHARE_RECEIVE_INTENT).setType("*/*")) }) {
Text("Launch receiving UI")
}
}
}
}
}
companion object {
private const val QUICK_SHARE_SETTINGS_INTENT = "com.google.android.gms.settings.SHARING"
private const val QUICK_SHARE_RECEIVE_INTENT = "com.google.android.gms.RECEIVE_NEARBY"
}
}
@Composable