1. AC Question's Avatar
    Issue only on L device. On other devices the app works fine.

    After wrapping an app, we extend an existing activity with a wrapping activity.
    Now lets say the existing activity has onResume overridden and calls super.onResume (duh!).
    Without wrapping the app (i.e without extending it to wrapping activity) the app works fine. But if i run the app after wrapping, the wrapping activity's onResume is not getting called. (ExistingActivity extends WrappingActivity, so a super call in ExistingActivity should call onResume of WrappingActivity.)

    Here is the weird part, if i put a debugger on, everything works as expected.

    Some tests i tried:
    1. Removed super.onResume from ExistingActivity. App crashes on start, as expected.
    2. Removed super.onResume from WrappingActivity, app does not crash whereas it should have. So super method is not called. Now i put a debugger on, now the app crashes as expected.
    3. Tried building hierarchies of classes. A extends B, B extends C, C extends WrappingActivity. super.onResume is called for A,B,C but not for WrappingActivity.
    4. If i dont override onResume in the ExistingActivity, then the onResume of WrappingActivity is getting called correctly.
    5. Checked at runtime that the super class for ExistingActivity is indeed WrappingActivity.
    6. Observation : Any overridden method in the ExistingActivity class does not respect super method call to WrappingActivity. If i remove the overriding method in ExistingActivity then corresponding methods in WrappingActivity are correctly called.

    Any ideas around this weird issue is greatly appreciated.
    Thanks.
    03-31-2015 03:30 AM
  2. srkmagnus's Avatar
    Issue only on L device. On other devices the app works fine.

    After wrapping an app, we extend an existing activity with a wrapping activity.
    Now lets say the existing activity has onResume overridden and calls super.onResume (duh!).
    Without wrapping the app (i.e without extending it to wrapping activity) the app works fine. But if i run the app after wrapping, the wrapping activity's onResume is not getting called. (ExistingActivity extends WrappingActivity, so a super call in ExistingActivity should call onResume of WrappingActivity.)

    Here is the weird part, if i put a debugger on, everything works as expected.

    Some tests i tried:
    1. Removed super.onResume from ExistingActivity. App crashes on start, as expected.
    2. Removed super.onResume from WrappingActivity, app does not crash whereas it should have. So super method is not called. Now i put a debugger on, now the app crashes as expected.
    3. Tried building hierarchies of classes. A extends B, B extends C, C extends WrappingActivity. super.onResume is called for A,B,C but not for WrappingActivity.
    4. If i dont override onResume in the ExistingActivity, then the onResume of WrappingActivity is getting called correctly.
    5. Checked at runtime that the super class for ExistingActivity is indeed WrappingActivity.
    6. Observation : Any overridden method in the ExistingActivity class does not respect super method call to WrappingActivity. If i remove the overriding method in ExistingActivity then corresponding methods in WrappingActivity are correctly called.

    Any ideas around this weird issue is greatly appreciated.
    Thanks.
    Have you taken a look at the new documentation for developing with Lollipop support: http://developer.android.com/about/v.../lollipop.html
    03-31-2015 05:41 PM

Similar Threads

  1. S5 will not send/receive calls or texts
    By Peanut651 in forum Samsung Galaxy S5
    Replies: 4
    Last Post: 10-01-2015, 02:44 PM
  2. How can I get 11ac working on my Samsung Note 4?
    By AC Question in forum Samsung Galaxy Note 4
    Replies: 1
    Last Post: 03-31-2015, 08:40 AM
  3. significant battery usage after 128gb micro sd card inst
    By kevjey in forum Samsung Galaxy Note 4
    Replies: 4
    Last Post: 03-31-2015, 02:34 AM
  4. Why does my phone restart when I try to install or uninstall any apps?
    By VishweshG in forum General Help and How To
    Replies: 1
    Last Post: 03-31-2015, 01:58 AM
  5. Replies: 1
    Last Post: 03-31-2015, 01:22 AM
LINK TO POST COPIED TO CLIPBOARD