How to display an iphone search bar on down gesture?

Joey shared this question 6 years ago
Answered

I am prototyping an iphone application and need to create a screen that has an initially hidden search bar, under the primary navigation. The remainder of the screen is composed of a set of fields from a datamaster. I cannot figure out how to push the dynamic content down the page to display the search bar on a "down swipe" gesture and I haven't found a tutorial that explains something like this.

Comments (3)

photo
1

What I'd do is this: draw the entire screen with the search bar visible. Then create an event like this: onPageLoad -> set focus on 'the first field in your screen'. That way when you open that page the search bar will be hidden. Then the page scroll will do the rest.


The other way is to take a look at this tutorial to know how to push content dynamically using events and define an event like that using the gesture 'on slide down': http://www.justinmind.com/prototyper/...

photo
1

Thank you Victor, that did work. However, I need to take this one more step. Above the search bar, I have a "Refreshing" bar which slides down on down swipe as well. After a 3 second pause, I want the "Refreshing" bar to disappear. Using the swipe down to either hide this panel or reduce the size(y) coordinate to 1, but nothing happens on swipe down. Does swipe down not work on a datagrid inside of a dynamic panel? I have attached an image of the refresh panel. 638e7b865700be1f83e9a023b28c51f8

photo
1

That looks like something too specific to try to solve it from here. Can you contact jim.support at justinmind.com and send them the prototype?