Some more thoughts on cross-platform mobile development (MonoTouch, MonoDroid and Windows Phone 7) from yesterday's post - a 'rosetta stone' (not this one) to translate between the three platforms (Not that each of these things is exactly equivalent - they're matched up where the concept/role/function seems similar to me).
|"View"||XIB (Interface Builder)||Xaml||axml|
|UITableViewCell||ListBox.ItemTemplate||n/a (any view)|
|UITableViewSource||n/a (binding, IEnumerable)||BaseAdapter|
|Navigation "Controller"||NavigationController. PushViewController()||NavigationService.|
|n/a (object)||Xaml Uri||Intent.SetClass()|
|n/a (object properties)||Xaml Uri querystring params||Intent.PutExtra() .AddFlags()|
|n/a (object properties)||NavigationContext|
|"Model"||C# .NET objects - shared thanks to Mono on iOS & Android. Also |
One major difference between iOS and the other two (both in terms of coding and also UI design) is the presence of hardware buttons and the back-stack.
The most important hardware button is Back (covered next) however Android's Menu button is also significant for the impact is has on UI design compared to iOS and WP7. Both Apple and Microsoft's designers like the application menu (
ApplicationBar) to be permanently visible. Google, on the other hand, provides the Menu button to show the menu, meaning that most of the time it is hidden. This means your Android app UI might need to provide other visual clues so that navigation/features/options are more discoverable.
Both Android and WindowsPhone7 devices have a hardware Back button supported by the respective SDKs via the 'back-stack' which is analogous to your web-browser History: each "View" has an "address" (a Xaml
Uriin WP7, an
Intentin Android) which is stored as the user navigates through your application. At any time (unless you intercept it) the hardware Back button allows the user to cycle back through previous views until they have exited your app.
iOS utilises a similar navigation metaphor in its
UINavigationController- however the back button is 'soft' (displayed in the top-left corner of the screen) and the scope is limited to the set of views that the developer chose to include in that navigation context.