I would like to know the best practice approach to accomplishing this in Android:
Main Activity: Contains 1 textview, 1 opens menu and 1 global thread- based class. The global thread-based class that opens a socket and reads in data via TCP/IP, and sends thread-safe notification to the main activity so that it can update its textview. This class is developed and works well when it is called from the main activity's onCreate method. Preferences Activity: This activity allows the user to choose options for host and TCP/IP. Here are my questions: 1. How do I keep my global class from being destroyed when the onPause is called? Every time I rotate the phone or enter the preferences activity, the object is trashed. 2. How do I capture the event that the user has entered preferences and it is time to start my global class? I have tried onResume, but there is ambiguity between when the app is loaded and when the preferences screen was exited. Thanks in advance... -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en