Android的微调暗淡的背景 [英] Android spinner dim background
问题描述
我有一个微调藏在我的申请,显示它当一个按钮pssed $ P $(performClick ...)。我要的是,当显示微调,昏暗的背景,使重点是微调。就像当显示一个警告对话框,背景被变暗。我没有找到在微调文档任何东西。有什么建议?
I have a spinner hidden in my application and I show it when a button is pressed ( performClick... ). What I want is, when the spinner is displayed, to dim the background so focus is on the spinner. Like when an alert dialog is shown where background gets dimmed. I didn't find anything in the Spinner Documentation. Any suggestions?
推荐答案
您可以将与微调和其他元素之间的白色或黑色背景的完整布局视图,当出现微调/消失/出动画的阿尔法。在出动画的结尾,你需要设置它的能见度 View.GONE
来禁止它来收集用户的点击。
You can place a full layout view with white or black background between the spinner and other elements and animate its alpha in/out when the spinner appears/disappears. At the end of "out" animation you need to set it's visibility to View.GONE
to disallow it to gather user's clicks.
这篇关于Android的微调暗淡的背景的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!