MvvmCross dialog on android, modal on ios - ios

I have a screen with 1 button. When clicking that button, a list of items should be shown (in which the user can select multiple items).
On android, i would like to do this using a dialog. I create a "DialogService" that does this, no problem.
On iOS, however, it seems that the best practice is to display a fullscreen tableview, for example as a modalView. Is it possible to do this without using a custom viewpresenter (e.g. modalViewPresenter)? I would very much prefer to have identical navigation on both platforms and just have different implementations of "DialogService"

I think trying to make one platform look and act like another is generally not a great idea as things start to look weird for the users.
But if you want to do it anyway I would start by trying to do something like this https://stackoverflow.com/a/29910246/1107580 (it is in objective-c) then trying to bind to the tableview that is in the alertcontroller.

Related

Tabbed iOS WebKit Browser with Swift

In short I am trying to build some typical browser functionalities in a Swift iOS app with WKWebViews (WebKit). I already have a functioning browser based on a WKWebView, which already has a menu bar with a URL input, navigation buttons, a share button, page title etc.
What I am struggling with is creating tabs for the browser. At first this seemed trivial as surely WKWebViews would support this in some way. Well, as far as I can tell they do not (looked at and tried multiple tutorials incl. hackingwithswift, Ray Wenderlich etc. + I checked Apple's documentation + stackoverflow)
This is what I have come up with so far:
1) Creating a new tab/opening a new URL should create a new UIView + WKWebView programmatically (I'll have to make a subclass out of my current browser view)
=> this should create a separate thread for each WKWebView/tab according to Apple's documentation
2) I need something like a Collection View (or Stack Views etc.) to store screenshot images of the already open tabs as a preview page of all tabs. The cells should be linked via a delegate to the corresponding WkWebView and they should have a close button to close (= delete) the tabs.
Am I overthinking this? If I go down this path I have to find a way to wire up (and subsequently delete) multiple delegates and views to the Collection View dynamically and I have to store & delete screenshots every time the user interacts with the tabs. It seems VERY messy. But given that Chrome on iOS is based on WebKit as of late, it's obviously doable.
How would you tackle this problem?
PS I didn't include a mockup because you all know how the tabs in Chrome, Safari etc. on iOS look like.
EDIT:
I am just looking for a clean and sensible way to add/remove and show the multiple WKWebViews, which are created by opening new tabs - just like in Chrome for iOS or Safari etc.
Ok, I have solved this today :) I will have a main UIView and then multiple WKWebViews, which can be "zoomed in" in order to enter full screen mode. No need for screenshots etc.

Replicate iOS Pattern: Instagram Search-Style Swiping Tabs

I'm starting a new iOS project in Swift, and my experience programming native iOS applications is minimal, so please bear with me if I use some whacky terminology or overlook some simple solutions.
I'm looking to replicate a pattern in the Instagram application, as seen here:
Selected Tab
Swiping Transition
For those who don't use Instagram, what's essentially going on here is something like a UIPageViewController (with swiping functionality), but with the tabs on top indicating the selected page.
Like in Instagram, I'm planning to have this functionality within a child UIViewController of a UITabBarController (you can see the "main" tabs on the bottom).
What I started out doing was creating static tabs and adding left and right gesture recognizers to the child UIViewController, which would change the page and update the indicator of the selected page on the tabs.
This works but I'm not really loving the way it looks, nor the way it's written. I don't like the idea of needing 2 instances of the tabs, and that certainly doesn't seem to be the way Instagram is doing it, because as shown in the second image, the indicator slides between the tabs.
I've searched a fair bit, but all references to replicating Instagram patterns seem to be outdated and don't address this specific element. Like I said, though, I haven't been programming native iOS for very long (I'm an Android developer and have used Xamarin for iOS), so it's possible I'm just not using the right keywords.
I'd appreciate any help y'all can offer!
Thanks

Spinner in iOS, like in Android

I am very first time developing the Spinner in iOS.
I searched a lot for default Spinner view in iOS, but failed.
What I get is, two ways to design spinner like view in iOS.
UIPickerview
Custom TableView which will be displayed on Click of DownArrow Button
I found the tutorial for UIPickerview.
But There are some OS orientation for this,
Means I want the UIPickerview in different Look & feel with selection style, also Scrolling of picker is not as I want.
So I was thinking to go for second options.
But Is there any other superior way to achieve this task,
As I think the second option is GOOD, but NOT BEST.
What I want is like the image below, its from Android,
I want to go for the same in iOS.
Thanks for help..
I think what you are looking is here
But I use RMPickerViewController which is more powerfull.

iOS design guidelines - tabcontrol versus list view for main/first selection screen

Since Apple developer account is down, I can take the chance of later submiting and getting rejected since I will then run out of time.
Suppose I have 9-11 menu items in main window navigation. It is a bit too much, but that is what customer explicitly requested.
The Android version uses a listview and it works and looks good. It does so on iOS. However, I can see most iOS apps use a tabcontrol at bottom with extra tabs at (...) Is that a strict requirement in all cases? (I can't really say one of the menu items are more important that the other.)
No, using a tab bar controller is not a requirement, that's a design choice. Whether to use a tab bar controller or a list view depends on how you navigate around in your app, and what you want the user experience to be. If you want the user to be able to switch easily and quickly between different modes of the app, or different views of the same data, then probably a tab bar controller would be appropriate. On the other hand, if the choices you're making initially, are not made often, and you have a large number of choices (like you do), then a table view is probably more appropriate.

Tab Bar like WhatsApp

How do I create a tab bar like WhatsApp on BlackBerry in my BlackBerry app? I want that feature in BlackBerry OS 7.0. I have used managers -- HorizontalFieldManager and VerticalFieldManager -- to achieve it. But it doesn't look as attractive as WhatsApp. Can FieldTabController help me do this?
It's not going to look attractive if you are just making tweaks to the code, and then seeing what that looks like. You need to start with a design you find attractive. Once you have that goal put together as an image, you start writing code to make the UI look like the design image.
The WhatsApp tab bar is not a straightforward combination of built-in UI managers from RIM. It has a fair amount of customization - each tab has three visual states, and there is a tooltip that follows the focus, as well as a context tab on the right that changes depending on the currently selected main tab. This means there are several interacting UI components here, not just a single magic manager.
Essentially, you will probably want to start building your own custom Field objects.
Basically, subclass the Field class (or one of the other subclasses), and learn to love the paint(..) method and the Graphics API.

Resources