On Tue, Jul 14, 2009 at 12:12 AM, magicpig <zsumagic...@gmail.com> wrote:
Thanks Dianne for the quick reply. My two Application.java do some more things than having the statics: 1. own the ability to store current activity for use in all the activities in the same process. (In the former description, I just talked about two for simple). 2. Creating some instances for later use(maybe can be moved to statics) So, if there is a way for replacing this easily, I am happy to do. BTW, I think we can read the process name, right? Thanks a again. On Jul 15, 1:58 am, magicpig <zsumagic...@gmail.com> wrote: > Thanks for the reply. > > I am trying hard to merge them together and the Application logic > seems a little more than setting the globals, such performing > differently on onLowMemory, onTerminate and onConfigurationChanged. > > So,is it possible to get the intent that starts the activity or the > different process name in Application#onCreate? > > Thanks > > On Jul 14, 2:20 pm, Dianne Hackborn <hack...@android.com> wrote: > > > Sorry, you can't do that. There are really very few reasons to have a > > custom Application anyway. I would generally suggest staying away from it, > > and just using statics for your globals. > > > On Mon, Jul 13, 2009 at 11:17 PM, magicpig <zsumagic...@gmail.com> wrote: > > > HI, > > > > I need two activities run in different processes in the same > > > application. Now I have made it work by specifying the different > > > process name in "android:process". > > > > But I met a problem, from > > > >http://developer.android.com/guide/topics/manifest/application-elemen... > > > , > > > we have only one superclass of Application will run before the > > > activity starts(I have tested it, and each time a after new processes > > > start, this Application(its superclass) will run before activity). > > > But, my two activities have two different superclasses of > > > Applications. So, how to make Applications for different activities > > > run for its corresponding activity? > > > > If there is no way to use different Application class for > > > different activity, how can I make a flag for the common Application > > > superclass to judge which process(by getting its name) is running? > > > > BTW, the two activities were on the separated development flow > > > and I am trying to merge them. > > > > Thanks a lot. > > > -- > > Dianne Hackborn > > Android framework engineer > > hack...@android.com > > > Note: please don't send private questions to me, as I don't have time to > > provide private support, and so won't reply to such e-mails. All such > > questions should be posted on public forums, where I and others can see and > > answer them. > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---