baker icon indicating copy to clipboard operation
baker copied to clipboard

Enable landscape view only for videos

Open morands opened this issue 14 years ago • 12 comments

Hi guys, in my publications there are some YouTube videos that I'd like to enable for landscape mode, but videos are the only part of the app that I want in landscape: I tried to modify the orientation options on both the Xcode project and on the book.json file but I can't reach my goal. Anyone has an idea?

Thanks in advance, Ed

morands avatar Jan 29 '12 13:01 morands

Then make your books in landscape mode? it's really not a good idea to ask the user rotate the iPad just for watching the video.

zenz avatar Jan 30 '12 02:01 zenz

@zenz I'm considering to leave only portrait also for videos, 'cause I'm working on a magazine and I can't make both versions every month.

morands avatar Jan 30 '12 07:01 morands

I'd have to test this, but I'm pretty sure the video can be viewed in portrait mode even though the Baker app is only landscape, when the user selects fullscreen.

Simbul avatar Feb 06 '12 21:02 Simbul

@morands so, you mean that by building the book as portrait only, then playing a video and then turning the iPad, the video doesn't turn?

folletto avatar Feb 14 '12 00:02 folletto

Hi @morands any news on this issue?

Simbul avatar Feb 20 '12 21:02 Simbul

Hey @Simbul! I have been pretty busy with school and another project recently... I should take a look to Baker for the end of this week (at least I hope). I'll keep you updated :)

morands avatar Feb 20 '12 22:02 morands

Cool, we'll be waiting :)

Simbul avatar Feb 20 '12 22:02 Simbul

Hi @Simbul and @folletto sorry for the wait but I finally made some tests with the "initial" Baker (without my changes). I tried many configurations and basically we can reassume as:

  1. Info.plist: all orientations enabled + book.json: only portrait = videos always in portrait
  2. Info.plist: all orientations enabled + book.json: both = videos in landscape and also contents

So I can see fullscreen videos in portrait only if I enable also the "normal content" to portrait. Any idea about how could I solve it?

morands avatar Feb 25 '12 17:02 morands

It seems that the code we use to handle the screen rotation influences the video as well.

It seems there's something to detect the video entering and exiting full screen, but it's on javascript side. I should try to see if there's an equivalent on Objective-C side. It might be possible, but unfortunately it requires some research and rework.

folletto avatar Feb 27 '12 22:02 folletto

I asked the question on Stackoverflow, to double check: http://stackoverflow.com/questions/9473688/detect-when-a-html5-video-runs-full-screen-from-objective-c

folletto avatar Feb 27 '12 22:02 folletto

I'm afraid that question didn't have any answer and as such is probably either impossible today or too complex to achieve. Sorry. :(

folletto avatar Mar 05 '12 20:03 folletto

Don't worry ;)

morands avatar Mar 05 '12 20:03 morands