So:
- Activity has NavigationView with action bar.
- There are 2 fragments - #1 and #2.
- In fragment #2 I need to hide action bar.
Ok, successfully did it with
getSupportActionBar.hide()
But when I return to previous fragment and call
getSupportActionBar.show()
content of fragment #1 is moved down on the height of my actionbar.
I've tried to call .show() method onPause() of fragment #2, onResume() of fragment #1, onCreateView() of fragment #1 (before inflating a view) - no result, half of my floatingActionButton is moved below the screen.
OnCreateView() is called in fragment #1 after dismissing fragment #2, but it seems that view is not redrawing. Any ideas how can I solve this?