It is necessary to somehow impose a grid on top of the screen, so that at the same time clicking on the elements behind this grid will be processed. How can this be implemented?
- What is the functionality of the grid? What is the idea? Can it be enough to make such a background? - Chubatiy
- need more information, at least an image with a design. - Nikotin N
- if my answer helped to fix the problem, check it out by checking the box. This will be a sign of the correctness of the answer for others, who will look for information - Flippy
|
1 answer
For this there is a FrameLayout . For example, here in the foreground is a half-transparent “film”, and behind it the ProgressBar
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="fill_parent" android:layout_height="fill_parent" android:orientation="vertical"> <ProgressBar android:layout_height="wrap_content" android:layout_width="wrap_content" android:layout_gravity="center"/> <LinearLayout android:layout_height="match_parent" android:layout_width="match_parent" android:background="#85000000"/> </FrameLayout> Replace ProgressBar with Layout with your buttons and set the grid :)
- not. elements are arranged in order of
XML. I just made thebackgroundforLinearLayoutcompletely black. He closed theProgressBar. If you were right, then the black background would be under theProgressBar. You probably did not understand what I meant. - Flippy
|