Re:Bringing Smiles to the Faces of MacOS developers - Miguel...
by anonymous245 on Tuesday October 12, 2010 @10:33PM
(#1785830)
Thank you for giving some sane advice, instead of peddling the magical "single source/multiplatform" promise.
Re:Bringing Smiles to the Faces of MacOS developers - Miguel...
by Tamerlin on Wednesday October 13, 2010 @11:36AM
(#1787479)
I agree, that's good advice -- it's what Sun should have done with Java instead of pushing the least common denominator UI libraries, which lead to a host of lousy UI's that worked equally poorly on every supported platform. :)
Our recommendation to developers is that they split their applications across the User Experience/Business Logic fault line. Developers then can replace the user experience with native user interfaces for each platform.
This is a bit abstract, so we tend to tell people to build a lot of UI-less reusable libraries and for libraries that have UIs, to split their Model-View-Controller libraries in a way that the Model and its support infrastructure are reusable and the View and the Controller are UI-specific.
This extends a little bit further. You also might end up with an "OS" layer that performs certain tasks in a different way depending on the operating system that you will be running.
For instance, while running on an iPhone, you have access to the gyroscope, something that you wont find on say a Linux desktop. Or on Linux, you will have access to /proc, which you wont have access to on Windows Mobile 7.
A nice example was Paint.NET. When that application was built, the operating-system specific features were all placed on a library called SystemLayer.dll. The UI was all Windows.Forms, but porting the program turned out to be limited to replacing the SystemLayer.dll with one that spoke Posix as opposed to speaking Win32.