Page 2 of 11

Facebook Style Navigation

Posted: Wed May 29, 2013 10:31 am
by doubletake

I did try you div code first. That didn't work, so I started trying various ways to see if I could get it to work and haven't found a way yet. using the j_63 was just one of those attempts. Neither work.


Facebook Style Navigation

Posted: Wed May 29, 2013 10:33 am
by doubletake

Would you please make a single page on your own that uses the above code that works? And send me a link to it?

Thanks,
Don


Facebook Style Navigation

Posted: Wed May 29, 2013 10:47 am
by Kateryna Grynko

Hi Don,

Yes, we'll create one.


Facebook Style Navigation

Posted: Wed May 29, 2013 12:13 pm
by Kateryna Grynko

Facebook Style Navigation

Posted: Wed May 29, 2013 1:12 pm
by doubletake

Thanks Katya! Appreciate it.

Is there a way you can give me a link to a version I can load into Appery.io to see how you did the code (plugin or something?) vs. just viewing the source?

Don


Facebook Style Navigation

Posted: Wed May 29, 2013 1:19 pm
by doubletake

Nevermind. I think I can see how you did in the source.

I see that the listview itself is assigned the side_panel class.

I'll give it a try.

Thanks!


Facebook Style Navigation

Posted: Wed May 29, 2013 1:20 pm
by Kateryna Grynko

Don,

Please send me email to a href="mailto:support@appery.io" rel="nofollow"support@appery.io/a and I'll send you project backup to be sure :)


Facebook Style Navigation

Posted: Wed May 29, 2013 3:56 pm
by doubletake

Thank you Katya for sending me the working sample app. Very helpful! I really appreciate you talking the extra time to build the example app. It helped me figure out the two issues:

1) Don't assign the .side_panel class to a panel div, assign it to the listview itself.
2) don't use div[data-role="page"] if you have more than one page.

I got it working for multiple pages by changing the prependTo code on the second page to this ...

var currentPage = Appery('Screen1');
panel2.prependTo(currentPage);

Thanks Katya!


Facebook Style Navigation

Posted: Thu May 30, 2013 1:50 pm
by Kapow36

Thanks doubletake for figuring out how to create the panel slide out navigation on multiple pages. My question is... why can't I add events to the list buttons? Well... I can, but they aren't called when the button is clicked.


Facebook Style Navigation

Posted: Thu May 30, 2013 2:27 pm
by doubletake

Kapow36 ... yep ... doesn't work. Bummer :(

I think it is because we detach the panel, but I'm not sure.

Here is a workaround that works for me.

In your load event, add event listeners after you create the panel.

...
panel.parent().trigger( "create" );

whole panel just to test
$('.side_panel').bind('click',function(evt) {
alert('panel clicked');
});

this one is for a item in the list ...

Appery('mobilelistitem_32').bind('click',function(evt) {
alert('li clicked');
});

In short, it looks like you have to write the click events yourself to navigateTo, etc.

Don