Thanks for the reply.... >From the docs : public static final int COMPONENT_ENABLED_STATE_DISABLED Since: API Level 1
Flag for setApplicationEnabledSetting(String, int, int) and setComponentEnabledSetting(ComponentName, int, int): This component or application has been explicitly disabled, regardless of what it has specified in its manifest. Constant Value: 2 (0x00000002) There is no state mentioned in manifest for the upgraded component, it should be in Disabled state until user enables it or Factory reset of phone is done. Please can anybody help to understand why component got enabled after BOTA upgrade. Is it a bug in android framework ?? or I am missing something here? On 6/26/12, Justin Anderson <[email protected]> wrote: > My guess, though I very well may be wrong, is that it is because the > enabled/disabled state in the manifest file of the upgrade app overwrites > the enabled/disabled state of the component. > > Thanks, > Justin Anderson > MagouyaWare Developer > http://sites.google.com/site/magouyaware > > > On Tue, Jun 26, 2012 at 5:38 AM, Sudeep Sharma > <[email protected]>wrote: > >> Hi, >> I am using PackageManager API to disable some component. >> >> ComponentName name = new ComponentName(context, className); >> className ==> the class object of the class i wanted to disable. >> This class is my Home category with higher priority than Homescreen app. >> >> Now while disabling the class i wanted to give flag >> PackageManager.DONT_KILL_APP because i do not want all the activities >> running in that package to die immediately. >> pm.setComponentEnabledSetting(name, >> PackageManager.COMPONENT_ENABLED_STATE_DISABLED, >> PackageManager.DONT_KILL_APP); >> >> Now if i upgrade my phone with BOTA package placed in SD card and when >> my phone boots up, i see that my componet(className) got enabled and >> my class is recieving the Home Intent instead of the actual HomeScreen >> app. >> >> All my settings and userdata is still persisting. Why the component >> gets enabled after upgrade ??? I think its not the behaviour that is >> expected. The component should still be disabled. >> >> Thanks, >> Sudeep >> >> -- >> You received this message because you are subscribed to the Google >> Groups "Android Developers" group. >> To post to this group, send email to [email protected] >> To unsubscribe from this group, send email to >> [email protected] >> For more options, visit this group at >> http://groups.google.com/group/android-developers?hl=en > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to [email protected] > To unsubscribe from this group, send email to > [email protected] > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en

