在邮递员上点击 oauth/access_token API 时,我收到无效平台应用程序错误。
注意 - 对于 app_id,我使用的是 Instagram 应用程序 ID。
有什么解决办法吗?
{
"error_type": "OAuthException",
"code": 400,
"error_message": "Invalid platform app"
}
Run Code Online (Sandbox Code Playgroud)
我正在使用 BottomSheetDialogFragment 来显示底部工作表。如何去除暗淡的背景?
我已经制作了透明背景,但是当底部工作表弹出时,它下面的背景会变暗。
class ClearDataBottomSheet : BottomSheetDialogFragment {
private lateinit var contentView: View
constructor() {
}
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
}
override fun onCreateDialog(savedInstanceState: Bundle?): Dialog {
val dialog = super.onCreateDialog(savedInstanceState) as BottomSheetDialog
dialog.setCancelable(false)
dialog.setOnShowListener { dialog ->
val d = dialog as BottomSheetDialog
val bottomSheet = d.findViewById<FrameLayout>(com.google.android.material.R.id.design_bottom_sheet)
BottomSheetBehavior.from(bottomSheet!!).state = BottomSheetBehavior.STATE_EXPANDED
}
// Do something with your dialog like setContentView() or whatever
return dialog
}
override fun setupDialog(dialog: Dialog, style: Int) {
super.setupDialog(dialog, style)
contentView = …
Run Code Online (Sandbox Code Playgroud)