-<!DOCTYPE html><html><head><title>Sencha Documentation Project</title><link rel="stylesheet" href="../reset.css" type="text/css"><link rel="stylesheet" href="../prettify.css" type="text/css"><link rel="stylesheet" href="../prettify_sa.css" type="text/css"><script type="text/javascript" src="../prettify.js"></script></head><body onload="prettyPrint()"><pre class="prettyprint"><pre><span id='Ext-tree.ViewDDPlugin'>/**
-</span> * @class Ext.tree.ViewDDPlugin
- * @extends Ext.AbstractPlugin
- * <p>This plugin provides drag and/or drop functionality for a TreeView.</p>
- * <p>It creates a specialized instance of {@link Ext.dd.DragZone DragZone} which knows how to drag out of a {@link Ext.tree.View TreeView}
- * and loads the data object which is passed to a cooperating {@link Ext.dd.DragZone DragZone}'s methods with the following properties:<ul>
- * <li>copy : Boolean
- * <div class="sub-desc">The value of the TreeView's <code>copy</code> property, or <code>true</code> if the TreeView was configured
- * with <code>allowCopy: true</code> <u>and</u> the control key was pressed when the drag operation was begun.</div></li>
- * <li>view : TreeView
- * <div class="sub-desc">The source TreeView from which the drag originated.</div></li>
- * <li>ddel : HtmlElement
- * <div class="sub-desc">The drag proxy element which moves with the mouse</div></li>
- * <li>item : HtmlElement
- * <div class="sub-desc">The TreeView node upon which the mousedown event was registered.</div></li>
- * <li>records : Array
- * <div class="sub-desc">An Array of {@link Ext.data.Model Model}s representing the selected data being dragged from the source TreeView.</div></li>
- * </ul></p>
- * <p>It also creates a specialized instance of {@link Ext.dd.DropZone} which cooperates with other DropZones which are members of the same
- * ddGroup which processes such data objects.</p>
- * <p>Adding this plugin to a view means that two new events may be fired from the client TreeView, <code>{@link #event-beforedrop beforedrop}</code> and
- * <code>{@link #event-drop drop}</code></p>
+<!DOCTYPE html>
+<html>
+<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <title>The source code</title>
+ <link href="../resources/prettify/prettify.css" type="text/css" rel="stylesheet" />
+ <script type="text/javascript" src="../resources/prettify/prettify.js"></script>
+ <style type="text/css">
+ .highlight { display: block; background-color: #ddd; }
+ </style>
+ <script type="text/javascript">
+ function highlight() {
+ document.getElementById(location.hash.replace(/#/, "")).className = "highlight";
+ }
+ </script>
+</head>
+<body onload="prettyPrint(); highlight();">
+ <pre class="prettyprint lang-js"><span id='Ext-tree-plugin-TreeViewDragDrop'>/**
+</span> * This plugin provides drag and/or drop functionality for a TreeView.
+ *
+ * It creates a specialized instance of {@link Ext.dd.DragZone DragZone} which knows how to drag out of a
+ * {@link Ext.tree.View TreeView} and loads the data object which is passed to a cooperating
+ * {@link Ext.dd.DragZone DragZone}'s methods with the following properties:
+ *
+ * - copy : Boolean
+ *
+ * The value of the TreeView's `copy` property, or `true` if the TreeView was configured with `allowCopy: true` *and*
+ * the control key was pressed when the drag operation was begun.
+ *
+ * - view : TreeView
+ *
+ * The source TreeView from which the drag originated.
+ *
+ * - ddel : HtmlElement
+ *
+ * The drag proxy element which moves with the mouse
+ *
+ * - item : HtmlElement
+ *
+ * The TreeView node upon which the mousedown event was registered.
+ *
+ * - records : Array
+ *
+ * An Array of {@link Ext.data.Model Models} representing the selected data being dragged from the source TreeView.
+ *
+ * It also creates a specialized instance of {@link Ext.dd.DropZone} which cooperates with other DropZones which are
+ * members of the same ddGroup which processes such data objects.
+ *
+ * Adding this plugin to a view means that two new events may be fired from the client TreeView, {@link #beforedrop} and
+ * {@link #drop}.
+ *
+ * Note that the plugin must be added to the tree view, not to the tree panel. For example using viewConfig:
+ *
+ * viewConfig: {
+ * plugins: { ptype: 'treeviewdragdrop' }
+ * }