Youtube-like video control bar in the bottom - ios

In the youtube app there's a possibility to collapse video into a small preview window with a playback and controls while you navigating in the different parts of the app. By tapping on the window you can always switch to full screen mode again.
I wonder: what't the best approach to implement similar functionality? For now I see few options but I'm not very well aware of the implications of these options.
Note: I have an iPhone tabbar based app.
Create a popover modal view controller, that is presented on top of current navigation stack in a current tab
Create a view and stick it to the bottom of the screen.
Create a view in bounds of a tabbar controller
Create a modal view controller embedded in tabbar controller.
Just from the list I suspect that using a specialized UIView (2) would be the worst possible way to do this. But I don't know about the rest. Any advice would be greatly appreciated.

Related

Bottom toolbar for all screens in iOS

I am new to iOS development and have a question about what component I should be using for a particular UI aspect. The app I am working on has need for a toolbar to go across the bottom and at times to be visible across all screens. This toolbar is going to be used to manage the playing/pausing of some audio files which will play as the user navigates between screens within the app. My question is should I be using a Toolbar, a Navigation Bar or something else to achieve this?
To create such a toolbar you can use whichever component you want. There is no built-in solution on iOS for such a scenario and there is anything in the human interface guidelines that may help you to make this decision.
From my perspective, the problem here is how to make this toolbar visible on all your screens. This depends on your view controllers hierarchy which I know anything about.
Navigation controller
If you use UInavigationController to organize your screens you can use it's built-in toolbar to achieve your goal. The drawback is that the UIToolbar of UINavigationController is per item view controller so you will need to configure it each time a new UIViewController is pushed on the stack.
Containment
The general solution is using the containment API. You can create let's say root view controller of your application which will contain your toolbar and will host other view controllers of your application. For the presentation purpose, I configured it on a storyboard using a container view. You can see it on the image below.
Modal presentations
Neither of above solutions will work when you decide to display a view controller modally. In this case, you will need to make additional effort to put the toolbar in such a view controller.
Other options
You probably won't be able to achieve that using UITabBarController unless you are very stubborn. But if you are new to iOS I don't recommend trying. The same is for UIPageViewController. I'm not sure about UISplitViewController because I have a very little experience with it.

How to always show a viewcontroller even when navigating screens in iOS?

I have this music player view controller that can be minimized. Thanks to LNPopupController[https://github.com/LeoNatan/LNPopupController].
Everything is working fine, but I have no idea how to make this music player view controller stays on top even when the user navigates to the other screens (even when the main navigation controller pushes another view controller). The app doesn't use tab bar controller by the way.
So, is there a way to implement this kind of idea? Again, sticking the minimized view controller on top of every screens of the app?
Developer of the framework here.
If you present the popup bar from a navigation controller, it will appear for all pushed controllers. Likewise for a tab bar controller.
If you need to have it for all controllers, it's not easily possible. One way is the have your entire application scene appear as a child controller of a view controller, and have that controller present the popup bar. This is a difficult way to make it work, and not recommended. It has many issues.
The popup controller is not meant to appear on the screen all the time. It is meant to implement a similar functionality as Apple's.
add the minimized view controller on keyWindown which your minimized view controller always on top ,I didnot Know whether can help you,the code demo gif as is show,If anyone need Demo,give me Email:59620one463qq.com(replace one to 1) to get demo

How to get facebook like sliding menu without using third party files in ios?

I'm struck to implement it. I want to display a menu, which is already pushed into navigation controller. I know i have to use transition with animation method in which i have to increase the width from 0 to required value. But this is not helpful coz navigation controller takes care of presenting VC when we pop it. So how to implement it in ios?
Use a separate UIWindow for the menu, so you do not interfere with the UINavigationController.
You can have the menu behind your content window and move the content window to make the menu visible.

"Slide" segue between UITabBar views

My iOS 5 app uses storyboarding with a UITabBarController. There are three "tabs" each displaying a view controller which has been linked using a relationship back to the UITabBarController. At the moment each view controller appears when you tap the relevant tab, as expected. However, for a more gracious transition I would like to slide the view controllers on and off screen.
By way of example, if I am currently on Tab 0 and then select Tab 1 the view controller on screen (for Tab 0) should slide off to the left-hand side of the screen, and the new view controller (for Tab 1) should slide on from the right-hand side of the screen.
I have been able to achieve this behaviour using a custom UIView as the tab bar but would like to know whether this is possible with a custom segue in storyboarding, as that would certainly save a lot of coding (and also would keep things a fair bit neater in the project)?
Thanks in advance for any assistance.
I am trying to do the same thing.
Unfortunately I think the relationship segue does not allow any customization as it just connect tab bar and the tab bar items together, and not a transition.
My guess is we have to do the transition ourselves when the view appeared.

UISplitView : Need to hide left view for initial two screens

I have gone through various threads and tutorials but not able to find any solutions, so need to post the question. So the questions is :
For initial three screens need to display only the detail view without any popover button at navigation bar in landscape. Now in third screen on button click i need to load the splitview with both left and right view.
I am aware of the methods which hides the left view panel in landscape mode. The only part i am worried id to load the splitview from 3rd screen .So need some suggestion to proceed further.
Thanks.
Try Matt Gemmel's custom split view controller.

Resources