How to make an iPhone spinner? - ios

I am creating an iphone application, where i am getting confuse. I need to show a control (displaying Online option) as i have mention in below screenshot. I have seen such type of controls in Android.
When user will press, it should display Offline and Online two options in one small pop up view. Selected option text will come on to the control field. How to implement or give me suggestion to show such type of field in iphone.
Thanks in Advance.

Check the answer here: Any pull down or drop down menu for iOS?
Personally I would make a text box with an image view to make it look like a drop down box. then on tap load a UIActionSheet for the user to select from.

Related

How to add a check mark to a selected option in Action Sheet IOS option in react native?

I was working on react native app in which I need to change few values in a component after user has selected an option.
To select an option I open action sheet in IOS. Now I wanted to show the current selected option in the Action Sheet by adding a check mark.
I was able to see this in podcast app of iphone as attached in the screenshot.
I was also able to see few native implementations of this in here , but I wanted this to work in case of react native.
Can someone please help?
Easy way to do is to use destructiveButtonIndex property of the Action Sheet. It cannot add a check mark, but at least will change the colour of the option to orange. In this case, user can know which one is checked before.

Add custom menu option to JSQMessagesViewControllerCell

I am building a chat app that uses JSQMessagesViewController. The default functionality includes the ability for a user to long press a chat bubble which then presents a copy menu option (see screenshot). I would like to add an additional custom menu for reporting a comment. Ideally when the user long presses a chat bubble the menu now has two options, copy and report. Can someone please point me in the right direction for adding this custom menu button? Thank you!
See the demo file
https://github.com/jessesquires/JSQMessagesViewController/blob/develop/JSQMessagesDemo/DemoMessagesViewController.m
See the use of customAction

How to create radio buttons and drop down menu bar in Swift (for iOS app development)?

I am beginner in iOS app development and am creating an app where I need to create radio button and drop sown menu bar using swift .
Please suggest me, how could I do that ??
Welcome to SO. In general, this site isn't really suited to "show me how to do <development task>" questions. It's intended for specific technical questions about code you are trying to get working.
I'll take pity on you since this is your first post.
Neither radio buttons nor drop-down menus are standard iOS controls. You should consider using iOS standard user interface elements instead.
The iOS equivalent of radio buttons is a segmented control (UISegementedControl)
The iOS equivalent of a drop-down menu is a UIPickerView.
If you really want radio buttons and drop-down menus you could create them yourself, but as a beginner that is likely over your head. You might want to look for open source components that do what you need. Try checking out CocoaControls. There are lots and lots of custom controls. You can likely find what you're looking for there under a reasonable source license like the MIT license.

Selecting from multiple lists in iOS (iPad)

I'm new to iOS developing and want to know how to make a menu (btn1,btn2,...) on which when you click on it to be taken to a list of documents (example1,example2,...) and when you on them to display a preview of the document, and the option to view it in iBooks or Pages.
Like the image below.
Thank you :)
http://i.stack.imgur.com/wEli4.png
You can make a UITableView to display various options. On selection of an option you can show them a UISplitViewController with left being a list and right side being a preview. Note that you cannot push a UISplitViewController but just add it as subview.

iPhone/iPad UI: seeking drop-down control

My universal app has a settings page, wherein the user must choose a theme from a dozen available themes.
Problem is, if I am using a picker-view, it takes up most of the screen on an iPhone.
I think what I want is something like your standard Windows drop-down menu, where it just displays on a single line the current selection, and clicking it expands into a scrollable list of possible items. Selecting an item collapses the list back into the original form.
So my question is: What is my best method for handling this situation? Can anyone point me to pictures or code examples of how this situation is handled successfully?
EDIT:
This is the behaviour I'm looking for:
only the currently selected profile is displayed
when the user taps on this, it expands into a list
when the user selects an item (or taps outside of the view) it collapses back to its original form, now displaying the new selection
ie functionally equivalent to a dropdown.
Firstly, this question is a duplicate of:
(not much good) Picker view as subview
(same) How to make an iPhone dropdown-looking button
(better) How to create drop down list box for an iphone app
(even better) Creating a drop-down list in iPhone app
(that last one links to some handy code)
Secondly, Google image search for 'dropdown control iphone' restricting the image size to 320x480 shows how everyone is doing this.
Basically a picker view scrolls in from the bottom, the same way as the keyboard does.

Resources