MvvmCross-AndroidSupport
MvvmCross-AndroidSupport copied to clipboard
#275 MvxCachingFragmentCompatActivity GetLastFragmentInfo() does not …
…return the last added fragment.
- Removed unnused usings
- Removed double casting
- Used .ToFragment() extension method.
- Created _lastFragmentTag
- Filling _lastFragmentTag within ShowFragment if Fragment is cacheable
This way GetLastFragmentInfo doesn't rely on SupportFragmentManager.Fragments ArrayList anymore.
After the first time that ShowFragment has been called, and a Cacheable fragment is displayed, _lastFragmentTag is filled with its last shown fragment tag.