moving an item depending on scroll amount of dynamic panel?

I'm creating an Android App prototype with App Bar at the top, and a long content beneath it in a dynamic pane that is a exactly device screen size.

What I'd like to do is pushing away AppBar out of the screen and bringing it back depending on scroll amount of contents in a dynamic panel. So as a user, while consuming contents as scrolling up, App bar is out of screen and when s/he scrolls back up, Appbar comes back to the screen.

I've tried,

1. Put 'On Scroll' event on AppBar with condition 'if SY > 0'

2. " 'If absolute position of the dynamic panel < 0'

None of them worked. Is there anyone can help me out with this issue? I can't find any similar questions answered.

What I want to do is, a screen starts like the first one, once scroll up the white box thing above the list pinned below AppBar, once the list comes back to the top, the pinned box transforms back to what it was before.