I am trying to write an Applescript to play a sequence of movies in the same player window in fullscreen mode without interruption. So far I have been able to close “document 2” after starting play of “document 1” (the playing movie seems to always be document 1) but this causes the tabs at the top of the screen (full screen) to appear and then disappear.
Is there a way to play a sequence of movies without either opening new player windows/tabs or without showing the player window tabs in full screen?
here is what I have so far (as a test of two consecutive movies):
tell application “QuickTime Player”
activate
set thisFile to open POSIX file “/Volumes/OWCRaid/Projects/Working Projects/Morpho 3 Upscale/Converted MOV/morph04.mov”
tell thisFile
present
play
tell application “QuickTime Player”
set MovieSeconds to (duration of document 1) as string
delay MovieSeconds
— close document 1
try — try will ignore error generated when first movie is played
close document 2
end try
end tell
— close
end tell
activate
set thisFile to open POSIX file "/Volumes/OWCRaid/Projects/Working Projects/Morpho 3 Upscale/Converted MOV/morph05.mov"
tell application "QuickTime Player"
try
close document 2 -- if not first movie played, will keep only one player window open
end try
end tell
tell thisFile
present
play
tell application "QuickTime Player"
set MovieSeconds to (duration of document 1) as string
delay MovieSeconds
try -- try will ignore error generated when first movie is played
close document 2
end try
end tell
-- close
end tell
end tell
I tried the above script and it works to limit the number of open instances but results in a brief view of the Quicktime full screen window tabs.