android – What's the NoSaveStateFrameLayout?-ThrowExceptions

Exception or error:

I’ve been reading about layout optimization from the Android Dev blogs and I’ve been using hierarchyviewer to see where I can possibly flatten or merge layouts/elements. But here is something that I keep seeing in my view hierarchy…NoSaveStateFrameLayout. Can anyone shed some light on this? It shows up (usually) before a LinearLayout and it seems quite useless and just adds another (unnecessary) level to the hierarchy. I tried searching for what this is but I’ve had no luck.

How to solve:

It’s an implementation detail of the support library’s fragment implementation. This is the comment from it:

/**
 * Pre-Honeycomb versions of the platform don't have {@link View#setSaveFromParentEnabled(boolean)},
 * so instead we insert this between the view and its parent.
 */

Leave a Reply

Your email address will not be published. Required fields are marked *