[Music]
so let's take a look at what happens
when you quit an app now I've got a
couple of apps open here and the first
one is preview and I have a PDF document
open in preview now I can quit using
command Q or go to preview quit preview
the same thing either way when I do that
and then I run preview again what
happens is the document I was looking at
will just simply open again to the same
position and if I multiple documents
open all of them will open again
now I'm gonna hide that and look here
and I've got Safari and actually if two
windows open it so far I've got this one
window with a Wikipedia article I have
another window here that actually has
two tabs in it so I'm going to quit
Safari and when I reopen Safari look
what happens I get both of those windows
open and all the tabs and all those
windows open again so this is normal
behavior but you can choose to actually
close all of the windows for these apps
if you want so for instance in preview
here I could of course just closed the
window hit the red X there and that
would close that window close that
document and then it could quit preview
I could also go to preview and hold the
option key down on my keyboard and you
could see it changes from quit to quit
and close all windows so I can select
that and now when I launch preview again
it doesn't open up that document matter
fact it goes to the default kind of
selected document thing the same thing
here with Safari I go Safari quit Safari
hold the option key down and you can see
it changes to quit and close all windows
now if you prefer to always close all
windows when you quit you can do that go
to System Preferences and under System
Preferences click on general and there's
an option here called closed windows
when quitting app if you check that
then go back to safari quit Safari will
work in that everything is closed and
now when I run Safari again and this is
the same for preview and everything else
it starts fresh all those windows are
gone now notice when I do that if I hold
the option key down quit Safari changes
to quit and keep windows so option
command Q does the opposite you can
either keep quit and close all windows
if you have it set one-way or quit and
keep windows when you haven't said the
other way so you always have the
opportunity to do the opposite of what
you have it set for in System
Preferences by holding the option key
when using command Q or selecting the
application and the quit function now
let's say that you quit an app a quit
preview here and I have it set so that
it's not going to close windows when
quitting apps so now when I launch
preview again I have no choice it's
going to bring up the documents that
were open before but there is a way to
get around that if you've got the app in
the dock in this case I moved preview to
the dock then you can hold the shift key
down and launch and let's say I won't
hold the shift key down here I'll launch
and you can see it brings back that
document but if I hold the shift key
down and launch it will not do it it
will launch clean the same thing is true
with Safari if I click on Safari and
then I go to a site I quit I launch
Safari again you can see it's going to
return to that site so let me quit again
and now I'm going to shift in launch
Safari then it will close all the
windows so you can kind of do it retro
actively when you launch the app the
next time by simply holding the shift
key down that only really works
I believe it if the app is in the dock
or if you're launching it from the
Applications folder it doesn't seem to
work if you're doing a spotlight search
and trying to launch it that way
[Music]