1
00:00:00,330 --> 00:00:02,090
Hello this is Mortaza court.

2
00:00:02,130 --> 00:00:07,110
And in this tutorial you're going to implement the undestroyed method inside our floating youth service

3
00:00:07,110 --> 00:00:14,290
class in order to prevent memory problems later when our application is actually published.

4
00:00:14,580 --> 00:00:21,990
So here inside this class we can implement this method after this unbind method but make sure that you

5
00:00:21,990 --> 00:00:25,820
implement this method before the Indian curly place of our class.

6
00:00:25,830 --> 00:00:33,590
So now I can't just step in and destroy and inside the Smurfit after this super edit and destroy Colling

7
00:00:33,640 --> 00:00:46,130
here I am going to say if floating widgets is not equal to gnarl if our vision is not actually not.

8
00:00:46,150 --> 00:00:57,620
And this means that this visit is still in memory and taking space then we are going to say window manager

9
00:00:58,360 --> 00:01:01,070
that removes view.

10
00:01:01,520 --> 00:01:04,860
The view is going to be floating widgets.

11
00:01:05,570 --> 00:01:06,840
So that's it.

12
00:01:06,920 --> 00:01:13,610
In this way their view their vision is going to be removed from the window manager and the memory is

13
00:01:13,610 --> 00:01:14,600
going to be emptied.

14
00:01:14,600 --> 00:01:16,790
So thank you very much for watching.

15
00:01:16,960 --> 00:01:23,720
In the next tutorial we're going to put permissions inside the main activity class because we need to

16
00:01:23,720 --> 00:01:33,610
ask the user to directly give us the permission to draw our widget over other apps or the Android on

17
00:01:33,620 --> 00:01:34,570
the screen.

18
00:01:35,000 --> 00:01:39,670
And then when the user gives us the permission we can shorten widgets to the user.

19
00:01:39,830 --> 00:01:43,400
So thank you very much for watching and I look forward to seeing you in the next two Oreo.

