Skip to content

Instantly share code, notes, and snippets.

@jeffremer
Created February 5, 2011 00:39
Show Gist options
  • Save jeffremer/812068 to your computer and use it in GitHub Desktop.
Save jeffremer/812068 to your computer and use it in GitHub Desktop.
Flexible vbox layout
{
index: function(interaction) {
var panel = new Wbx.views.AbstractView({
layout: {
type: 'vbox',
align: 'stretch'
},
defaults: {
flex: 1
},
dockedItems: [
{
html: 'Some docked text',
height: 80
}
],
items: [
{
html: 'Some text',
listeners: {
afterrender: function(me) {
this.mon(this.el, 'tap', function() {
Wbx.views.Msg.alert('Alert', 'Some text');
})
}
}
},
{
html: 'Some text',
listeners: {
afterrender: function(me) {
this.mon(this.el, 'tap', function() {
Wbx.views.Msg.alert('Alert', 'Some text');
})
}
}
},
{
html: 'Some text',
listeners: {
afterrender: function(me) {
this.mon(this.el, 'tap', function() {
Wbx.views.Msg.alert('Alert', 'Some text');
})
}
}
}
]
});
this.renderIndex(panel, interaction);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment