Is it possible to disable the white flash which appears during Shared Element Transitions? I have a dark theme in my Android app, and the white flash makes the app unpleasant to use whenever there's a transition. While there were some questions regarding this issue, I couldn't solve this problem in my app so far.
(e.g. the cause for the blinking was in this stackoverflow question a NavigationDrawerLayout, but my transition gets started in my Activity after a view been clicked in a Fragment)
styles.xml
<!-- enable window content transitions -->
<item name="android:windowContentTransitions">true</item>
<item name="android:windowAllowEnterTransitionOverlap">true</item>
<item name="android:windowAllowReturnTransitionOverlap">true</item>
This method starts a new transition in my Activity
@TargetApi(Build.VERSION_CODES.LOLLIPOP)
private void startItemDetailActivityTransition(Item pItem, boolean pForceComments, View pTransitionView) {
Intent intent = new Intent(this,ItemDetailActivity.class);
ActivityOptions options = ActivityOptions.makeSceneTransitionAnimation(this, Pair.create(pTransitionView, getString(R.string.transition_item)));
intent.putExtra(ItemDetailActivity.EXTRA_ITEM, pItem);
intent.putExtra(ItemDetailActivity.EXTRA_FORCE_COMMENTS, pForceComments);
startActivity(intent, options.toBundle());
}
Thanks for the help