-
Sencha User
How to include ext.ux class into my view?
Hi,
I got this link from github, https://github.com/elmasse/Ext.ux.Cover
please help me in easy steps to integrate this plugin in to my view.
I am but confused in arranging the files in my folder structure after unzip this.
my folder structure,
folderstrecture.png
-
-
Sencha User
Suggest me on using the example
Hi jay,
Thanks for ur reply.
Actually later i downloaded the example only. Could you please suggest me the code how to run it in my view, becoz the example code starting with launch:function(), i tried with it. I have one main view, inside by clicking a button a view and inside this should come.
I placed the ux under touch/src/ux here, Css added in my css and images added.
My view:
Ext.define("MyBank.view.peronalizeviewtheme", {
extend: 'Ext.Container',
xtype: 'peronalize-view-theme',
config: {
height: '100%',
style: 'background-color: #000000',
layout: {
type: 'vbox'
},
items: [
{
xtype: 'titlebar',
border: '0px',
docked: 'top',
style: 'backgroundColor: #FCD00D',
ui: 'plain',
title: 'Personalized Us',
items:[
{
style: {
backgroundImage: 'url(touch/resources/images/imgNavBtnBackNormalL.png)'
},
width: '49px',
height: '29px',
xtype: 'button',
align: 'left',
text: 'Back',
ui: 'plain',
action: 'LocatorPopNav'
},
{
style: {
backgroundImage: 'url(touch/resources/images/imgNavBtnSmallNormal.png)',
backgroundColor: 'transparent',
},
width: '60px',
height: '29px',
xtype: 'button',
align: 'right',
text: 'Login',
text: 'Login',
ui: 'plain',
action: 'navigatelogin',
},
]
},
{
xtype: 'panel',
layout: { type: 'vbox'},
pack: 'centre',
align:'centre',
items: [
<!-- how to integrate here coverflow code-- >
]
}]
}
});
Collected Example.js code:
Ext.application({
name: 'MyAlbums',
requires: ['Ext.ux.Cover'],
launch: function(){
var store, cover;
//create a store
store = Ext.create('Ext.data.Store',{
fields: ['album', 'artist', 'year', 'artwork'],
data: [
{album: 'In Between Dreams', artist: 'Jack Johnson', year:'2005', artwork: './artwork/InBetweenDreams.jpg'},
{album: 'On and On', artist: 'Jack Johnson', year:'2003'},
{album: 'Back in Black', artist: 'AC/DC', year:'1980'},
{album: 'Jailbreak 74', artist: 'AC/DC', year:'1974'}
]
});
//create the coverflow
cover = Ext.create('Ext.ux.Cover', {
fullscreen: true,
store: store,
itemCls: 'album-cover',
itemTpl: [
'<div class="artwork">',
' <tpl if="artwork"><img src="{artwork}">',
' <tpl else><img src="./artwork/album.png"></tpl>',
'</div>',
'<div class="description">{album} <br/> {artist} ({year})</div>'
]
});
store.sort("artist");
//add it to viewport
Ext.Viewport.add(cover);
}
});
please suggest me
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules