Name of the View or iOS Component used in the gif? - ios

This is the way i need to create (gif).
The Above gif shows a view which pops up from bottom while clicking on the moto g3 button overlaying the parent view with some gestures to control it.
I would like to know the name of this view if available in the iOS components or any specific ways to create it.

Related

Add an inputview to UIButton for on click event iOS

I am building a page for a Swift iOS app and I want the user to be able to specify the date range for a graph. At the top of my graph I want the user to select a date range by clicking on a button which will gray out the screen and bring up a picker view on the bottom of the screen to select the date range. It's very similar to how the myfitnesspal app does it (below):
As you can see when they click on the calendar button it brings up a pickerview while graying out the rest of the screen and only recognizes touches to the pickerview. I basically want to replicate this kind of method that allows me to bring up a custom picker when a button is clicked.
I have tried using UIActionSheet however that is now deprecated and I've read that an action sheet should not be used for this kind of functionality.
You can do this by designing a view controller such that-
It has a background view that covers entire screen with background color as black with some alpha say 0.3. This view will serve to block out any touches on the views behind it. Basically it will have that translucent background effect.
Have your actual view such as picker view as a sibling of this, add other siblings like the cross button, etc. You can use the cross button to initiate closing of the view.
Present this controller as a child view controller on the controller where you need this.

iOS popover with a close button outside

I need to create below thing
Currently i'm using WYPopover , but I can't create the button since it's outside of the popover. Is there any existing solution out there ? Many thanks
Create a bigger popover UIView holding all your child elements (current popover + button) and make its background transparent or however you wish.
Popover-controller's are exclusively used in iPad. If you want to use in iPhone, you should create it in a custom way.
I am not familiar with the XYPopover in Github, but normally the custom created popover should be dismissed whenever the user taps any place in the screen. That is one of the key feature of the popovers.
Normally the custom popovers are build like, adding a hidden parent view and then the visible image of a popover frame on it.
You should to do the following,
Avoid dismissing the parent view on tap of parent-hidden-view.
Add a close button at the area where you want to show the close button, on top of the parent-hidden-view.
Capture the button click and dismiss the view (remove the view from superview)
How to customize your need
Creating custom popover view is not a big task. It will take maxim one day, try it your self.
One Parent view with clear color
One background image of a popover frame.
View-inside popover (this needs to be customized for UIPopover also).
Close button.

How to persist a slide-out sidebar menu through entire iOS app

Is there an established solution for how to create and persist a slide out sidebar menu (like on Facebook, or Spotify) so that it appears on any view in your iOS application? I've tried using MMDrawerController, but once i segue from the initial view, I lose the sidebar. I assume this is because I'm transitioning the entire viewController, and not just changing the centerViewController.
Of note, I am using a storyboard in my project, and would like to continue if possible.
If I have a GUI element that I want to persist permanently (or appear and disappear but be shared by multiple view controllers) then I create a root view controller and add the persistent gui elements to it and add a container view as a subclass of the RVC's main view which covers the entire size of the screen.
Then what ordinarily would have been your app's rvc is embedded within this container view.
In the example I've posted there is a UILabel on top of the container which of course could be anything (including a whole hierarchy of views, or another container view with another view controller embedded with in it, whatever you want). You can make it appear or disappear as need be throughout the rest of the program either by creating/destroying it as needed, or fading the alpha to/from 0, or changing the x.y co-ordinates to animate it onto/off of the screen etc.

Utilize iOS TabBar as TaskBar

I'm making an application that requires the use of a dock (think Mac dock) where I can have different items that I can drag out onto a map view.
It would make sense to me to just use and subclass a UITabBar, since you can easily add items to that bar in the interface builder. However, I'm not sure how I would transform a UITabBar into something more dynamic like the Mac dock, where things are only highlighted when the user touches them, copies of that tab can be dragged out, ect.
To that end, just a side question, what's the difference between the UITabBarDelegate and UITabBarControllerDelegate protocols?
I also thought of another way I could implement my task bar/dock using some sort of collection view with UIImageViews. That would be easier in terms of implementing drag and drop, highlight selection, ect but I would lose that nice, native iOS feel that the UITabBar has.
Any suggestions?
do one thing. create a custom class for tabbar add a view over it. and add image views over the view place small images in that view and add gesture recognizer over it. When the finger comes over it replace the smaller image with the larger one. and also change the tab bar selection if the user taps over it. you can do this by using tabbar property. or you call the tabbar delegate manually when the tap is made.

Disabling the detail view controller in a split view controller on the iPad in iOS 5

I have a split view controller in my iPad app. It has a list of Tenants for a mall on the left side and detailed information about the selected tenant on the right.
When you press the edit button on the master view controller (list of tenants) it should disable the right view controller (the detail view for the tenant). How do I accomplish this?
The only thing I can think of is adding a UIImageView with a semi transparent background and hiding/showing it when the master calls it's setEditing.
This functionality ships with the iPad. If you open up the Messages.app and hit the edit button in the master view (left), the conversation or detail view (right) becomes grey and disabled and you cannot interact with it until you hit "Done" on the left side. How can I do this in my app?
So long as the right view controller is the delegate of the master (which should be created for you anyhow, seeing as that's how the UISplitViewController object is supposed to be used), it's a simple call to a method you define yourself. Maybe pass some Boolean value through to indicate editing, and animate a black CALayer's alpha property in response.

Resources