View Full Version : Panel push example

15 May 2012, 8:28 AM

I'm fairly new to using Sencha, but have been following the example in the Getting Started Sencha Touch 2 walkthrough.

I'm trying to implement the blog example, which uses the list and the tap event which then pushes a panel with the full content of the blog article.

This works fine on Chrome when I test on my desktop, but if I view it through the browser on my android mobile it does not show the full blog article.

In the transition from the list to the panel, it appears to show the panel with the full article content on it, but this is then cleared once the "back" button and title are displayed.

Would there be any condition where it is refreshing the panel after loading the content?

The code for the controller is :

config: {
refs: {
news: 'newspanel'
control: {
'newspanel list': {
itemtap: 'showPost'

showPost: function(list, index, element, record) {
xtype: 'panel',
title: record.get('title'),
html: record.get('content'),
scrollable: true,
styleHtmlContent: true

I would appreciate any advice anyone could give on this.


17 May 2012, 5:32 AM
What do you mean cleared? If you push a panel, it will add that item to the navigation view and make it active. Tapping back will pop() the view meaning it will remove the item and it will be destroyed.

17 May 2012, 6:48 AM
Thanks for replying.

I suspect I havent described it as best I could.

What's happening is that when I click the headline in the list, it shows the panel correctly with the back button, headline as the title.

On chrome desktop and iphone it also displays the content of the news item on the panel under the title.

On my android browsers it simply displays a blank area under the title. However on the android browser when I tap the list item and it transitions to the panel, it briefly displays the content, and likewise when I click back again it does the same.

I hope that is slightly clearer as to the problem - I just followed Ed's example code and since it's working on some browsers I'm guessing it's maybe just an oddity with the android browsers?