Ooyala video player (iOS): how to ALWAYS hide video control? - objective-c

I use Ooyala video player in my project, and I need to have my own video control, so I need a way to hind its built-in video control, I found that the OOOoyalaPlayerViewController has method showControls, but the control appears when you tap the video, so is there a way to explicitly hide the controls? I've tried subclassing OOOoyalaPlayerViewController and overwrite showControls to do nothing but it did not work.
Thanks!

If you are creating custom controls, you probably want to use an OOOoyalaPlayer directly versus going through the OOOoyalaPlayerViewController- all the viewcontroller does is add controls on top of the player.
If you must use an OOOoyalaPlayerViewController, try subclassing OOControlsViewController and overwriting - (void)onTap:(UITapGestureRecognizer *)sender. The source for this is bundled with our SDK.

Related

Objective-c: Make a cocoa app to simulate media keys

I'm trying to simulate a press of this media buttons by code in a macbook:
The idea is to pause, rewind... the music with the uibuttons in my app. It's posible to do this? I did't find anything.
Something like this:
- (IBAction)playButtonClick:(id)sender {
//code here to play music, like if we pressed the physical play media key
}
I would draw images for that (probalby in two resolutions, one for retina and one for non-retina, while in most cases a retina version is sufficient) in two variations, one in regular mode and one as if the button is currently pressed.
Then use a simple UIButton object for each of them.
And right, when you create the buttons programmatically, then you can use
- (void)playButtonClick:(id)sender
as target for the play button. However, when you want to create and locate the buttons in Interface Builder or Storyboard Editor respectively, then it should be
- (IBAction)playButtonClick:(id)sender
which enables the IB to allow you to draw the connection to the action within IB accordingly.

How to have multiple proxy icons in Cocoa document windows?

Most Cocoa applications, provided they call NSWindow's -setRepresentedFilename:, will display a nice little proxy icon at the top-centre of their NSWindows.
Here's an example of the Preview app with a PDF document:
Xcode, somehow, manages to display 2 proxy icons - one for the project file and the other for the current document in the source display.
Does anyone know how they do that? window:shouldPopUpDocumentPathMenu: in NSWindowDelegate seems very close - you could probably position your custom path menus with this. But there doesn't seem to be anything that would allow you to actually display the two proxy icons themselves.
Any ideas?
Unfortunately Apple has access to APIs the rest of us don’t. Messing with the title bar is really hard.
The best I can suggest is making your window NOT have a standard title bar, and then placing the buttons yourself by calling [self standardWindowButton:X] for each of the close, resize, and miniaturize buttons you want. Then place your own document icon and title textField.
You’ll likely have to track when the window loses or gains key or main status and modify the buttons accordingly (Cocoa fetches new buttons each time this happens, not sure why). Whee! Good luck!

MPMoviePlayerController swapping videos flicker

I'm using MPMoviePlayerController to play different videos.
However, when I change the video using setContentURL (I'm just targeting OS 3.2 and above), I notice a white flicker.
Is there anyway I can get rid of that flicker and make the transition between videos look smooth?
Thanks,
Tee
Unfortunately not, and I've had this problem too. You could use another instance of the controller, and use an animation to transition from one video to the other, to have a bit more control over the process.

find out fullscreen button in youtube embedded player programatically

I wanted to know that is there any way to find out programatically the fullscreen button that is added on the youtube embedded player so that I can call an action on its touchupInsideEvent.
Please help.
Thanks in advance.
Shruti
In general, it's not possible to intercept events like that into the flash player, unless the SWF has some sort of an API for that purpose.
A different way to approach the problem is to use the YouTube "chromeless" player. It's basically an embedded player with no user interface elements. You provide the controls, which can command the player via the Javascript interface. You can intercept a user request for maximize that way.
There's even a question on Stack Overflow that concerns with fullscreen functionality for Chromeless players.

What is the UI element on iPad Photos App?

Please see the youtube:
http://www.youtube.com/watch?v=FC95ARd96wI
notice that the 0:35 , the iPad bottom have a thin photo bar. Is it a private API or I need to create my own or Which UI Element will it be? Thz.
That's definitely a custom job. However, it's basically a UIToolbar with a fancy slider on it. You can easily make the toolbar using Interface Builder, and you could take a simple stab at the slider by taking a regular UISlider and giving it some replacement images for its track, thumb, etc. See the documentation on UISlider.
If that doesn't quite work, then you're going to have to get down and dirty in UIControl code and make on yourself from scratch (or hope and pray that someone has written an open source version already).