WEBVTT

00:00.080 --> 00:00.960
Welcome back.

00:01.000 --> 00:05.360
We created has permission and launcher variables.

00:05.360 --> 00:08.360
Now let's use them by the UI.

00:08.560 --> 00:10.800
Create a box layout.

00:10.960 --> 00:22.640
Set the modifier to modifier dot fill maximum size and inside this box if has permission then what we

00:22.640 --> 00:27.400
need to do set the on granted and call it.

00:27.440 --> 00:33.680
If not, what we need to do, we need to create a new column.

00:33.680 --> 00:43.360
Inside this column, set the horizontal alignment to center horizontally and vertical alignment or arrangement

00:43.360 --> 00:49.560
arrangement dot center okay alt plus enter here the alignment and here we go.

00:49.680 --> 00:53.760
And by the way we need to set for the box alignment.

00:53.760 --> 00:59.240
So here content alignment alignment dot center.

00:59.400 --> 01:01.840
Then scroll down to here.

01:01.920 --> 01:07.240
We need to uh create two two Composables the text and the button.

01:07.360 --> 01:10.760
Uh the text camera permission required.

01:10.760 --> 01:18.640
Set a spacer between the text and the button, import the DP and set a button on.

01:18.640 --> 01:19.280
Click.

01:19.480 --> 01:20.680
What we need to do.

01:20.840 --> 01:23.320
We need to launch the launcher.

01:23.320 --> 01:33.640
So launcher dot launch manifest camera and set another composable inside this button saying that request

01:33.880 --> 01:37.480
or grant the grant camera permission.

01:37.480 --> 01:43.480
So when the user clicks the button we request the camera permission granted.
