1 // private - DD implementation for Panels
2 Ext.define('Ext.panel.DD', {
3 extend: 'Ext.dd.DragSource',
4 requires: ['Ext.panel.Proxy'],
6 constructor : function(panel, cfg){
8 this.dragData = {panel: panel};
9 this.proxy = Ext.create('Ext.panel.Proxy', panel, cfg);
11 this.callParent([panel.el, cfg]);
13 Ext.defer(function() {
14 var header = panel.header,
18 this.setHandleElId(header.id);
21 el.setStyle('cursor', 'move');
26 showFrame: Ext.emptyFn,
27 startDrag: Ext.emptyFn,
28 b4StartDrag: function(x, y) {
31 b4MouseDown: function(e) {
34 this.autoOffset(x, y);
36 onInitDrag : function(x, y){
37 this.onStartDrag(x, y);
40 createFrame : Ext.emptyFn,
41 getDragEl : function(e){
42 return this.proxy.ghost.el.dom;
44 endDrag : function(e){
46 this.panel.saveState();
49 autoOffset : function(x, y) {