Fast ANDroid Furious Android with C# in 20 minutes
What is Mono? <ul><li>Open source  implementation of the CLR </li><ul><li>Linux, MacOS X, Solaris, BSD, Wii, PS3
Started in 2001 as  Ximian , purchased by Novell  in 2003, released in 2004
2009: MonoTouch created (released 2010)
2010: MonoDroid created (released 2011)
2011: Novell purchased by Attachmate ($2.2b) </li><ul><li>entire Mono team sacked > startup  Xamarin  created... </li></ul...
http://github.com/mono   </li></ul>
What  is  was Mono for Android? Mono ('Silverlight subset') + Android API bindings  + 'AXML' intelli-sense support  + Visu...
Mono for Android System Req's <ul><li>To play in the simulator ( FREE ) </li><ul><li>Mac OSX  with MonoDevelop  OR   Windo...
Oracle's Java SDK
Google's Android SDK
Mono for Android Trial (and MonoDevelop IDE) </li></ul><li>To get onto a device </li><ul><li>Mono for Android Prof or Ente...
//TODO: <ul><li>Activity </li><ul><li>OnCreate </li><ul><li>SetContentView and FindViewById<T> </li></ul></ul><li>/layout/...
AndroidManifest.xml
Application </li><ul><li>OnCreate </li></ul><li>Intent </li><ul><li>PutExtra() and GetStringExtra </li></ul></ul>
 
<ul>Activity Lifecycle <li>Active/running
Upcoming SlideShare
Loading in …5
×

OzAltNet Fast-ANDroid-furious

1,309 views

Published on

F

Published in: Technology, Education
  • Be the first to comment

  • Be the first to like this

OzAltNet Fast-ANDroid-furious

  1. 1. Fast ANDroid Furious Android with C# in 20 minutes
  2. 2. What is Mono? <ul><li>Open source implementation of the CLR </li><ul><li>Linux, MacOS X, Solaris, BSD, Wii, PS3
  3. 3. Started in 2001 as Ximian , purchased by Novell in 2003, released in 2004
  4. 4. 2009: MonoTouch created (released 2010)
  5. 5. 2010: MonoDroid created (released 2011)
  6. 6. 2011: Novell purchased by Attachmate ($2.2b) </li><ul><li>entire Mono team sacked > startup Xamarin created... </li></ul></ul><li>http://www.mono-project.com/
  7. 7. http://github.com/mono </li></ul>
  8. 8. What is was Mono for Android? Mono ('Silverlight subset') + Android API bindings + 'AXML' intelli-sense support + Visual Studio plug-in (or MonoDevelop) = Android application <ul>http://mono-android.net/ </ul>Released April 2011 Retired May 2011??
  9. 9. Mono for Android System Req's <ul><li>To play in the simulator ( FREE ) </li><ul><li>Mac OSX with MonoDevelop OR Windows (VisualStudio 2010 or MonoDevelop)
  10. 10. Oracle's Java SDK
  11. 11. Google's Android SDK
  12. 12. Mono for Android Trial (and MonoDevelop IDE) </li></ul><li>To get onto a device </li><ul><li>Mono for Android Prof or Enterprise license (USD399+) </li></ul><li>To get onto Android Market </li><ul><li>Google Developer account (USD25) </li></ul></ul>
  13. 13. //TODO: <ul><li>Activity </li><ul><li>OnCreate </li><ul><li>SetContentView and FindViewById<T> </li></ul></ul><li>/layout/ , /res/ and R esources
  14. 14. AndroidManifest.xml
  15. 15. Application </li><ul><li>OnCreate </li></ul><li>Intent </li><ul><li>PutExtra() and GetStringExtra </li></ul></ul>
  16. 17. <ul>Activity Lifecycle <li>Active/running
  17. 18. Paused
  18. 19. Stopped
  19. 20. Killed/shutdown </li></ul>You should always call up to your superclass when implementing these methods
  20. 21. Details! <ul><li>Debugging
  21. 22. Linking
  22. 23. UI </li><ul><li>iOS
  23. 24. Android </li></ul><li>Navigation
  24. 25. Databinding
  25. 26. F.A.Q. </li></ul>
  26. 27. Debugging <ul><li>'soft debugger' gets embedded in your app </li><ul><li>Can be configured (IP address, port)
  27. 28. Binaries are much larger (of course) </li></ul><li>Allows breakpoints, step-through, call stack
  28. 29. Works via TCP/IP, so you can debug the Simulator AND the device (untethered, so long as wifi is enabled). </li></ul>
  29. 30. Linking <ul><li>Mono compiler strips out unused classes/libraries </li><ul><li>Mobile devices – size matters!
  30. 31. Trap for young players: it might strip out stuff you want to keep! </li><ul><li>Classes/methods/properties used via Reflection
  31. 32. Classes/methods/properties used in serialization operations </li></ul></ul><li>By default it's disabled in DEBUG, so stuff will work there and mysteriously break in RELEASE [ Preserve (AllMembers = true )] </li></ul>
  32. 33. Navigation <ul>Getting from screen to screen </ul><ul><li>StartActivity()
  33. 34. Intent </li><ul><li>SetClass typeof(AnActivity)
  34. 35. PutExtra
  35. 36. Can also 'trigger' other applications </li></ul></ul><ul><li>PushViewController()
  36. 37. UIViewController </li><ul><li>Subclass and pass instance </li></ul><li>… also UITabBar items </li></ul>
  37. 38. Databinding (lists) <ul>More work that you are used to... </ul><ul><li>BaseAdapter </li><ul><li>GetView
  38. 39. Count
  39. 40. GetItem
  40. 41. (.ItemClick is attached to the ListView itself) </li></ul></ul><ul><li>UITableViewSource </li><ul><li>GetCell
  41. 42. RowsInSection
  42. 43. RowSelected </li></ul></ul>
  43. 44. 'translation'
  44. 45. Example: RestGuide Runs on Android, iOS and Windows Phone 7 github.com/conceptdev
  45. 46. Example: MIX11 Runs on Android, iOS and Windows Phone 7 mix11.confapp.com
  46. 47. Any questions?
  47. 48. Professional iPhone w/ MonoTouch

×