iPhone Swipe UIKeyboard to Switch Views - iphone

I want to achieve something like this with my application and its keyboard.
http://www.youtube.com/watch?v=ajs1p5NCNw4 from 1:32 - 1:38.
How can you hide your keyboard by swiping it horizontally and show another view on its place? Is it possible with default keyboard or should I create my own view with few buttons which I'll need and then add the swiping? (I know how to do this, but I'm not sure if apple wouldn't deny the app in app store because I implement my own keyboard or something like that)

Those are custom views. It might be a scroll view with paging enabled and two subviews (the numerical keypad is one subview and items view is the other subview).
The app might be using the custom view in place of the system keyboard, by setting the inputView property of a text field for example. Or it might just be displaying the custom view as a subview of its top-level view.

Related

Content of UIPopoverController slides out of view when Keyboard is dispatched

I have an iPad app who's login screen looks like this (top of image clipped because of sensitive info):
When the user taps "Log In" button I load a UIPopoverController with some buttons:
When the user taps "Email" button, I release the first popover and create another one with two text fields:
Looking good so far, but when the user selects the text field in order to enter text, both of the UITextField controls slide off of the top of the PopoverController, like this:
I am using storyboards/segues for these popover controllers, with a little hand coded stuff to handle device rotations. I am using Autolayout and both of the UITextFields are pinned to the SuperView Top and Leading edge. That is all.
If I move the buttons up more towards the top of the screen (out of the way of the keyboard), this behavior is still present.
What is triggering this and where can I override its behavior?
Did you set the ContentSizeForViewInPopover for the view controller in -viewDidLoad showing textfields?
[self setContentSizeForViewInPopover:CGSizeMake(200, 200)];

iOS Navigation bar

I want to build an application with this kind of navigation between views:
a scrollview with text items (like a menu bar). Check Radio-Canada app on app store (free).
How to proceed? I know that I need a scrollview, but after that... You have to understand that I don't have too much experience with iOS 5.
Check this snapshot for an example:
snap http://www.eazyrf.com/Snap2.jpg
For a horizontal scrollview, just create a scrollview and add buttons to it. The white 'selected' background you clipped can be created by loading a white oval and using resizeableImageWithCapInsets: to extend it to fit the text. Link the button's click event to a function that presents the new view. If this 'menu bar' acts like a standard iOS tab bar, you'll need to manage the view hierarchy yourself.
For a vertical scrollview, most likely you're looking at a UITableView contained within a UINavigationController, where the class implementing UITableViewDelegate for the table view is responding to didSelectRowAtIndexPath by pushing a new view onto the navigation controller. This is a common pattern to implement what looks like a scrolling list of items, where tapping on one cell causes a transition to a new screen.

Mimicking iOS notification view

I am trying to mimic iOS 5's notification view (when you swipe down the view appears) for hub with a left swipe in my view. I created a mimic for a single view controller by adding the hubview as subview and changing the origin of view when making swipe. But With this approach I have to add it to every view I implement in my app. I want to add it to UIViewController as a category. I am not sure how to proceed at this point.
If you don't want every viewController to have to handle the menu then I would suggest having a root viewController that acts like a container. It has a subview that displays the content from your various view controllers and it also has the controls for your menu and any other overlay information you may want to provide.
A category won't work in this case but subclassing will. Just ensure that all of your view controllers are sub classes of the view controller with this functionality implemented.

How to define a custom keyPad in my App?

I want define a custom keyboard in my App,When I press one TabBar Item in my UITabBarController, then custom keyboard slide up, when I touch the the tabview, I hope the custom keyboard can slide down, But, Because the custom keyboard add in UITabBarController's view, and tableView add in UIViewController one of UITabBarController's ViewController, they are not in the same Class, How can I define the Keyboard, and add to which view?
I want to do like this:
When Press tab bar Item keyboard slide up,
http://i.stack.imgur.com/66NDu.png
When touch tableview, keyboard slide down.
http://i.stack.imgur.com/ZiHaR.png
Make a custom UIView with your custom keyboard buttons.
UITextField and UITextView have a property called inputView. If you set your custom view to this, iOS automatically takes care of resignFirstResponder and becomesFirstResponder messages on the text field.
This is the easiest way to use a custom keyboard.
Why are you declaring the custom keyboard in the UITabBarController class ? You can declare it in the view controller that is attached to that particular tabBarItem. If you add it to the that view controller, I am sure you can just make it resignFirstResponder or removeFromSuperView and manipulate it as you want.
Or you can just create a separate class for your customKeyboard, and add it along with your other classes. Simply include that class and create objects in other view controllers to manipulate them, and then release them. This is very easy and it is better programming compared to your approach, as at a later point of time, if you need to make changes or release 2.0 version of your app, it will come in handy and save some development time !

How would you create a static version of the UIPopoverView?

I tried using a popover in my interface, but all the convenience features of the UIPopoverController made it impossible.
My goal is to use the popover's chrome, but none of the associated events or actions. I need it to stay displayed onscreen (no dismissal) and not be modal.
So now I'm considering building my own view using images. My question: is there a better way to accomplish this (a view with image borders)?
If you want to stay your UIPopover onscreen and allow the user to interact with other views onscreen while to popover is show, consider using the passthroughViews property on UIPopoverController
The UIPopoverController Class Reference:
When a popover is active, interactions
with other views are normally disabled
until the popover is dismissed.
Assigning an array of views to this
property allows taps outside of the
popover to be handled by the
corresponding views.
You should be able to achieve the effect you want by just passing an array containing only the "background" viewcontroller's view.