04-24-2012 11:13 PM
Hi Im new to in developing in blackberry. Im trying to port my android code in blackberry Im just gonna ask how can you use a eventloop in blackberry java? because here in android its android.os.handler. Tnx in advance
04-25-2012 05:02 AM - edited 04-25-2012 05:03 AM
Welcome to the forums.
From my experience, you can't convert Android Event Handling directly into how the BlackBerry Java code manages its events. You need to completely rework that aspect of the processing, which is a little problematic if you are not familiar with the way that Events are processed in BlackBerry. Unfortunately I think the best advice I can give you is to spend some time working on understanding how the Blackberry works internally using BlackBerry code and then decide how you are going t convert your application.
You will find you need to throw away almost all your screen UI interaction too.
If you make use of 9patch, search the forum for a reference to code that someone here wrote to enable reuse of he assets. In my experience, these can be successfully reused in Blackberry, which is a saving. The business and data logic classes can similarly be reused. It is the UI and the Event handling code that needs to be re-written.