Hi fellow android developers,
I’m trying to implement a multi-pane layout as described here and an example implementation can be found in the codesample “HoneycombGallery”.
The only thing I changed is, that instead of using the normal getFragmentManager() I use the support-libraries and therefore the “getSupportFragmentManager()”. But now I have the following problem:
The getSupportFragmentManager().findViewById() returns a reference to a fragment even when the fragment is not on the screen :/
As you cann easily see, the example implementation uses this technique to differ between the to possibilyties, but the getSupportFragmentManager() returns a reference to a fragment in situations (for example after a orientation change and the second fragment disappeared as it is no longer in the layout) where it shouldn’t.
Has anyone also tried to get Multi-Pane-Layout working with the support-Fragments and FragmentManager?
Any hint is highly appreciated 🙂
Cheers
Ali3n
PS.: I could post some code if requested, but it actually is nearly the same code as in the example …
I fixed my problem, by not asking the FragmentManager for the fragment, instead I ask my layout for the view.