-
27 Dec 2010 7:24 AM #1
[OPEN-694] scroll:true messes up Ext.util.Draggable in Ext.DataView
[OPEN-694] scroll:true messes up Ext.util.Draggable in Ext.DataView
Sencha Touch version tested:
- 1.01
- only default ext-all.css
Platform tested against:- iOS 4 on Ipad
- Safari on Mac (Latest version)
Description:- When a Dataview is set to "scroll:true" the drag constraint is limited to the dataview itself. (can not be dragged to other components outside the layout)
Test Case:
Code:Ext.regModel('User', { fields: [ {name: 'name', type: 'string'} ] }); Ext.regApplication({ name: "Test", launch: function(){ droplist = new Ext.DataView({ scroll:true, flex:1, store: new Ext.data.Store({ model:'User', data:[ {name:'Fredric Berling'}, {name:'Bruce Springsteen'}, {name:'Michael Jackson'} ] }), tpl : [ '<tpl for=".">', '<div class="draggableDiv">{name}</div>', '</tpl>' ], itemSelector: 'div.draggableDiv' }); droplist.on('afterrender', function(){ droplist.on({ itemtap: this.createDragElement, scope:this }); }, this); this.viewport = new Ext.Panel({ fullscreen:true, application: this, layout: { type: 'hbox', align: 'stretch' }, items:[{xtype:'container', html:'drop here if you can', width:300 },droplist] }); },createDragElement:function(dw, index, item, e){ var dragItem = new Ext.util.Draggable(item, { revert:true, constrain:null }); } });
Steps to reproduce the problem:- Try crappy example above.. Click list item once for creating draggable.
- Now release mouse and try to drag the name item onto the left area.
- This doesnt work in my environment
- Now change scroll to false and reload page.
- Drag again into left panel. It should work
The result that was expected:- Dragging item into left panel
The result that occurs instead:- Item can only be dragged inside its own container. (the dataview)
-
14 Jan 2011 12:46 PM #2
-
2 Oct 2011 1:31 AM #3
I searched how to this bug solve but i cant find any suitable soulition. Then today when i'm looking for solution, i changed to senhca main css file
from x-scroller-parent{overflow:hidden !important;}
to x-scroller-parent{}
Now it working. But i think that it is not a good solution as well.
-
1 Feb 2012 7:40 AM #4
Do you have answer about this problem because i have the same and i implement AloneWalker 's solution but it is not a very good solution i think (but it works)
Thank you for reporting this bug. We will make it our priority to review this report.
Similar Threads
-
[OPEN-458] DataView - Scroll horizontal with one finger
By mitchellsimoens in forum Sencha Touch 1.x: BugsReplies: 1Last Post: 22 Oct 2010, 10:52 AM -
[OPEN-1141] Ext.util.Format.number Bug
By adam3342 in forum Ext 3.x: BugsReplies: 3Last Post: 21 Jul 2010, 9:27 AM -
ext-all.css line 1 messes up non-ext stuff in application/site
By zhegwood in forum Ext 3.x: Help & DiscussionReplies: 5Last Post: 6 Jan 2010, 7:17 PM -
[2.0rc1] Ext.Panel. draggable:true does not work.
By Animal in forum Ext 2.x: BugsReplies: 0Last Post: 21 Nov 2007, 6:28 AM


Reply With Quote