如何创建可移动的activity?
How to create movable activity?
我想知道如何执行从底部出现并卡在屏幕中间的可移动 activity,例如 android 棒棒糖联系方式或 android 棒棒糖选择器.
如果用户将它移到底部,我想停止 activity,就像这张 Borel 的详细图片
Borel detail picture
在设计支持库中使用 BottomSheetDialog。
下面是一个例子。
BottomSheetDialog mBottomSheetDialog = new BottomSheetDialog(this);
View view = getLayoutInflater().inflate(R.layout.your_layout, null);
mBottomSheetDialog.setContentView(view);
mBottomSheetDialog.show();
我想知道如何执行从底部出现并卡在屏幕中间的可移动 activity,例如 android 棒棒糖联系方式或 android 棒棒糖选择器. 如果用户将它移到底部,我想停止 activity,就像这张 Borel 的详细图片
Borel detail picture
在设计支持库中使用 BottomSheetDialog。 下面是一个例子。
BottomSheetDialog mBottomSheetDialog = new BottomSheetDialog(this);
View view = getLayoutInflater().inflate(R.layout.your_layout, null);
mBottomSheetDialog.setContentView(view);
mBottomSheetDialog.show();