我有容器。在那個容器裏面,我有3個可拖動的companent:如下圖所示:Sencha Touch 2.4.2 - 可拖動組件不在外面移動容器
我可以拖動父容器內的3個組件(上下移動) 但我需要將容器外的3個組件移動到左側,右側(箭頭標記)。
Screenshot of my current screen. I want to move the componets (10, 20, 30) to left side
是否有人可以幫助我在此。
這是我使用
{
xtype: 'container', //Middle Container
width: '100%',
height: '80%',
style: 'background-color: #669900',
layout: 'hbox',
items: [{
xtype: 'component',
itemId: 'markCompxx10',
draggable: true,
width: '100%',
height: '30%',
style: 'background-color: #00EE00',
html: '10',
listeners : { element : 'element', drag : function(e, t) { this.fireEvent('drag', this, e, t); }}
}, {
xtype: 'component',
itemId: 'markCompxx20',
draggable: true,
width: '100%',
height: '30%',
style: 'background-color: #00EE00',
html: '20',
listeners : { element : 'element', drag : function(e, t) { this.fireEvent('drag', this, e, t); }}
}, {
xtype: 'component',
itemId: 'markCompxx30',
width: '100%',
height: '30%',
style: 'background-color: #00FFEE',
html: '30',
listeners : { element : 'element', drag : function(e, t) { this.fireEvent('drag', this, e, t); }}
}]
}
}
感謝
有人對此問題有任何建議。我無法在互聯網上找到任何答案。感謝您的幫助 –