-1
A
回答
0
您可以创建具有透明背景的全屏对话框。
然后计算此循环的x/y点并放置箭头。
对话框的例子:
public void showDialog(Context context, View hourView) {
dialog = new Dialog(context, R.style.DreamDialogStyle);
dialog.setContentView(R.layout.dream_custom_add_photo_dialog);
// hourView in your case will be probably view with hour timer
// you need get for this view x and y position on your screen
// then in your dialog layout you need setX() and setY() for your loppView
// but your loopView will be full transparent background
// for position of x and y on screen You can use
// int[] array = new int[2];
// hourView.getLocationOnScreen(array);
// X = array[0] , Y = array[1]
// and in setX() setY() calculate loopSize for position loop on hourView
// And for arrow would be nice if You have image with this arrow.
// then You will need also calculate for your dilogTop and loopLeftDown
// and setAngle() in image for fill arrow line
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP){
dialog.getWindow().addFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS);
}
dialog.show();
}
对话样式为透明背景:
<style name="DreamDialogStyle" parent="Theme.AppCompat.DayNight.NoActionBar">
<item name="android:windowIsTranslucent">true</item>
<item name="android:windowBackground">@android:color/transparent</item>
</style>
相关问题
- 1. 如何创建100%自定义对话框片段
- 2. Android自定义对话框图像
- 3. 片段中的自定义对话框
- 4. 试图创建自定义对话框
- 5. Android创建意图内部对话框自定义视图
- 6. 在片段android创建一个自定义列表视图
- 7. 在android上创建自定义格式的对话框
- 8. 调用自定义对话框中的片段的Android
- 9. 在Cumulocity中创建自定义片段
- 10. 为片段创建自定义onClickListner
- 11. 在创建对话框片段时忽略对话框片段
- 12. 在wordpress中创建自定义字段和上传图像
- 13. Android自定义日历对话框片段
- 14. Android片段过渡自定义视图
- 15. 创建自定义对话框并在运行时操作它的字段
- 16. 自定义对话框片段不显示整个视图
- 17. 创建自定义jframe对话框
- 18. 创建自定义对话框
- 19. 如何创建自定义对话框
- 20. 以mfc创建自定义对话框
- 21. Wordpress自定义图片上传字段
- 22. 如何在自定义对话框中创建幻灯片?
- 23. 创建一个显示完整视图图像的自定义对话框
- 24. 创建iPhone自定义图片库
- 25. 自定义对话框上的自定义键盘(Android)
- 26. 在Android中创建自定义的“Open-With”对话框
- 27. 如何创建像Instagram一样的自定义照片视图?
- 28. Android - 片段中的对话框片段
- 29. 创建自定义平面开关android
- 30. 如何创建像自定义列表视图的自定义图像视图?