enable grammerly in editor
[roojs1] / docs / symbols / Roo.dd.DragDropMgr.json
1 {
2   "name" : "Roo.dd.DragDropMgr",
3   "augments" : [],
4   "desc" : "DragDropMgr is a singleton that tracks the element interaction for\nall DragDrop items in the window.  Generally, you will not call\nthis class directly, but it does have helper methods that could\nbe useful in your DragDrop implementations.",
5   "isSingleton" : true,
6   "isStatic" : false,
7   "isBuiltin" : false,
8   "memberOf" : "DragDropMgr",
9   "example" : "",
10   "deprecated" : "",
11   "since" : "",
12   "see" : "",
13   "params" : [],
14   "returns" : [],
15   "config" : [],
16   "methods" : [
17     {
18       "name" : "isDragDrop",
19       "desc" : "Utility function to determine if a given element has been\nregistered as a drag drop item.",
20       "isStatic" : false,
21       "isConstructor" : false,
22       "isPrivate" : false,
23       "memberOf" : "Roo.dd.DragDropMgr",
24       "example" : "",
25       "deprecated" : "",
26       "since" : "",
27       "see" : "",
28       "params" : [
29         {
30           "name" : "id",
31           "type" : "String",
32           "desc" : "the element id to check",
33           "isOptional" : false
34         }
35       ],
36       "returns" : [
37         {
38           "name" : "",
39           "type" : "boolean",
40           "desc" : "true if this element is a DragDrop item,\nfalse otherwise"
41         }
42       ]
43     },
44     {
45       "name" : "getRelated",
46       "desc" : "Returns the drag and drop instances that are in all groups the\npassed in instance belongs to.",
47       "isStatic" : false,
48       "isConstructor" : false,
49       "isPrivate" : false,
50       "memberOf" : "Roo.dd.DragDropMgr",
51       "example" : "",
52       "deprecated" : "",
53       "since" : "",
54       "see" : "",
55       "params" : [
56         {
57           "name" : "p_oDD",
58           "type" : "DragDrop",
59           "desc" : "the obj to get related data for",
60           "isOptional" : false
61         },
62         {
63           "name" : "bTargetsOnly",
64           "type" : "boolean",
65           "desc" : "if true, only return targetable objs",
66           "isOptional" : false
67         }
68       ],
69       "returns" : [
70         {
71           "name" : "",
72           "type" : "DragDrop[]",
73           "desc" : "the related instances"
74         }
75       ]
76     },
77     {
78       "name" : "getScrollLeft",
79       "desc" : "Gets the scrollLeft",
80       "isStatic" : false,
81       "isConstructor" : false,
82       "isPrivate" : false,
83       "memberOf" : "Roo.dd.DragDropMgr",
84       "example" : "",
85       "deprecated" : "",
86       "since" : "",
87       "see" : "",
88       "params" : [],
89       "returns" : [
90         {
91           "name" : "",
92           "type" : "int",
93           "desc" : "the document's scrollTop"
94         }
95       ]
96     },
97     {
98       "name" : "regDragDrop",
99       "desc" : "Each DragDrop instance must be registered with the DragDropMgr.\nThis is executed in DragDrop.init()",
100       "isStatic" : false,
101       "isConstructor" : false,
102       "isPrivate" : false,
103       "memberOf" : "Roo.dd.DragDropMgr",
104       "example" : "",
105       "deprecated" : "",
106       "since" : "",
107       "see" : "",
108       "params" : [
109         {
110           "name" : "oDD",
111           "type" : "DragDrop",
112           "desc" : "the DragDrop object to register",
113           "isOptional" : false
114         },
115         {
116           "name" : "sGroup",
117           "type" : "String",
118           "desc" : "the name of the group this element belongs to",
119           "isOptional" : false
120         }
121       ],
122       "returns" : []
123     },
124     {
125       "name" : "handleWasClicked",
126       "desc" : "Recursively searches the immediate parent and all child nodes for\nthe handle element in order to determine wheter or not it was\nclicked.",
127       "isStatic" : false,
128       "isConstructor" : false,
129       "isPrivate" : false,
130       "memberOf" : "Roo.dd.DragDropMgr",
131       "example" : "",
132       "deprecated" : "",
133       "since" : "",
134       "see" : "",
135       "params" : [
136         {
137           "name" : "node",
138           "type" : "",
139           "desc" : "the html element to inspect",
140           "isOptional" : false
141         }
142       ],
143       "returns" : []
144     },
145     {
146       "name" : "refreshCache",
147       "desc" : "Refreshes the cache of the top-left and bottom-right points of the\ndrag and drop objects in the specified group(s).  This is in the\nformat that is stored in the drag and drop instance, so typical\nusage is:\n<code>\nRoo.dd.DragDropMgr.refreshCache(ddinstance.groups);\n</code>\nAlternatively:\n<code>\nRoo.dd.DragDropMgr.refreshCache({group1:true, group2:true});\n</code>",
148       "isStatic" : false,
149       "isConstructor" : false,
150       "isPrivate" : false,
151       "memberOf" : "Roo.dd.DragDropMgr",
152       "example" : "",
153       "deprecated" : "",
154       "since" : "",
155       "see" : "",
156       "params" : [
157         {
158           "name" : "groups",
159           "type" : "Object",
160           "desc" : "an associative array of groups to refresh",
161           "isOptional" : false
162         }
163       ],
164       "returns" : []
165     },
166     {
167       "name" : "getCss",
168       "desc" : "Returns the style property for the DOM element (i.e.,\ndocument.getElById(id).style)",
169       "isStatic" : false,
170       "isConstructor" : false,
171       "isPrivate" : false,
172       "memberOf" : "Roo.dd.DragDropMgr",
173       "example" : "",
174       "deprecated" : "This has been deprecated: use Roo.getDom instead",
175       "since" : "",
176       "see" : "",
177       "params" : [
178         {
179           "name" : "id",
180           "type" : "String",
181           "desc" : "the id of the elment to get",
182           "isOptional" : false
183         }
184       ],
185       "returns" : [
186         {
187           "name" : "",
188           "type" : "Object",
189           "desc" : "The style property of the element"
190         }
191       ]
192     },
193     {
194       "name" : "swapNode",
195       "desc" : "Swap two nodes.  In IE, we use the native method, for others we\nemulate the IE behavior",
196       "isStatic" : false,
197       "isConstructor" : false,
198       "isPrivate" : false,
199       "memberOf" : "Roo.dd.DragDropMgr",
200       "example" : "",
201       "deprecated" : "",
202       "since" : "",
203       "see" : "",
204       "params" : [
205         {
206           "name" : "n1",
207           "type" : "",
208           "desc" : "the first node to swap",
209           "isOptional" : false
210         },
211         {
212           "name" : "n2",
213           "type" : "",
214           "desc" : "the other node to swap",
215           "isOptional" : false
216         }
217       ],
218       "returns" : []
219     },
220     {
221       "name" : "stopEvent",
222       "desc" : "Utility to stop event propagation and event default, if these\nfeatures are turned on.",
223       "isStatic" : false,
224       "isConstructor" : false,
225       "isPrivate" : false,
226       "memberOf" : "Roo.dd.DragDropMgr",
227       "example" : "",
228       "deprecated" : "",
229       "since" : "",
230       "see" : "",
231       "params" : [
232         {
233           "name" : "e",
234           "type" : "Event",
235           "desc" : "the event as returned by this.getEvent()",
236           "isOptional" : false
237         }
238       ],
239       "returns" : []
240     },
241     {
242       "name" : "lock",
243       "desc" : "Lock all drag and drop functionality",
244       "isStatic" : false,
245       "isConstructor" : false,
246       "isPrivate" : false,
247       "memberOf" : "Roo.dd.DragDropMgr",
248       "example" : "",
249       "deprecated" : "",
250       "since" : "",
251       "see" : "",
252       "params" : [],
253       "returns" : []
254     },
255     {
256       "name" : "moveToEl",
257       "desc" : "Sets the x/y position of an element to the location of the\ntarget element.",
258       "isStatic" : false,
259       "isConstructor" : false,
260       "isPrivate" : false,
261       "memberOf" : "Roo.dd.DragDropMgr",
262       "example" : "",
263       "deprecated" : "",
264       "since" : "",
265       "see" : "",
266       "params" : [
267         {
268           "name" : "moveEl",
269           "type" : "HTMLElement",
270           "desc" : "The element to move",
271           "isOptional" : false
272         },
273         {
274           "name" : "targetEl",
275           "type" : "HTMLElement",
276           "desc" : "The position reference element",
277           "isOptional" : false
278         }
279       ],
280       "returns" : []
281     },
282     {
283       "name" : "unlock",
284       "desc" : "Unlock all drag and drop functionality",
285       "isStatic" : false,
286       "isConstructor" : false,
287       "isPrivate" : false,
288       "memberOf" : "Roo.dd.DragDropMgr",
289       "example" : "",
290       "deprecated" : "",
291       "since" : "",
292       "see" : "",
293       "params" : [],
294       "returns" : []
295     },
296     {
297       "name" : "getDDById",
298       "desc" : "Returns the DragDrop instance for a given id",
299       "isStatic" : false,
300       "isConstructor" : false,
301       "isPrivate" : false,
302       "memberOf" : "Roo.dd.DragDropMgr",
303       "example" : "",
304       "deprecated" : "",
305       "since" : "",
306       "see" : "",
307       "params" : [
308         {
309           "name" : "id",
310           "type" : "String",
311           "desc" : "the id of the DragDrop object",
312           "isOptional" : false
313         }
314       ],
315       "returns" : [
316         {
317           "name" : "",
318           "type" : "DragDrop",
319           "desc" : "the drag drop object, null if it is not found"
320         }
321       ]
322     },
323     {
324       "name" : "isLegalTarget",
325       "desc" : "Returns true if the specified dd target is a legal target for\nthe specifice drag obj",
326       "isStatic" : false,
327       "isConstructor" : false,
328       "isPrivate" : false,
329       "memberOf" : "Roo.dd.DragDropMgr",
330       "example" : "",
331       "deprecated" : "",
332       "since" : "",
333       "see" : "",
334       "params" : [
335         {
336           "name" : "the",
337           "type" : "DragDrop",
338           "desc" : "drag obj",
339           "isOptional" : false
340         },
341         {
342           "name" : "the",
343           "type" : "DragDrop",
344           "desc" : "target",
345           "isOptional" : false
346         }
347       ],
348       "returns" : [
349         {
350           "name" : "",
351           "type" : "boolean",
352           "desc" : "true if the target is a legal target for the\ndd obj"
353         }
354       ]
355     },
356     {
357       "name" : "isTypeOfDD",
358       "desc" : "My goal is to be able to transparently determine if an object is\ntypeof DragDrop, and the exact subclass of DragDrop.  typeof\nreturns \"object\", oDD.constructor.toString() always returns\n\"DragDrop\" and not the name of the subclass.  So for now it just\nevaluates a well-known variable in DragDrop.",
359       "isStatic" : false,
360       "isConstructor" : false,
361       "isPrivate" : false,
362       "memberOf" : "Roo.dd.DragDropMgr",
363       "example" : "",
364       "deprecated" : "",
365       "since" : "",
366       "see" : "",
367       "params" : [
368         {
369           "name" : "the",
370           "type" : "Object",
371           "desc" : "object to evaluate",
372           "isOptional" : false
373         }
374       ],
375       "returns" : [
376         {
377           "name" : "",
378           "type" : "boolean",
379           "desc" : "true if typeof oDD = DragDrop"
380         }
381       ]
382     },
383     {
384       "name" : "startDrag",
385       "desc" : "Fired when either the drag pixel threshol or the mousedown hold\ntime threshold has been met.",
386       "isStatic" : false,
387       "isConstructor" : false,
388       "isPrivate" : false,
389       "memberOf" : "Roo.dd.DragDropMgr",
390       "example" : "",
391       "deprecated" : "",
392       "since" : "",
393       "see" : "",
394       "params" : [
395         {
396           "name" : "x",
397           "type" : "",
398           "desc" : "{int} the X position of the original mousedown",
399           "isOptional" : false
400         },
401         {
402           "name" : "y",
403           "type" : "",
404           "desc" : "{int} the Y position of the original mousedown",
405           "isOptional" : false
406         }
407       ],
408       "returns" : []
409     },
410     {
411       "name" : "getStyle",
412       "desc" : "Returns the specified element style property",
413       "isStatic" : false,
414       "isConstructor" : false,
415       "isPrivate" : false,
416       "memberOf" : "Roo.dd.DragDropMgr",
417       "example" : "",
418       "deprecated" : "This has been deprecated: use Roo.lib.Dom.getStyle",
419       "since" : "",
420       "see" : "",
421       "params" : [
422         {
423           "name" : "el",
424           "type" : "HTMLElement",
425           "desc" : "the element",
426           "isOptional" : false
427         },
428         {
429           "name" : "styleProp",
430           "type" : "string",
431           "desc" : "the style property",
432           "isOptional" : false
433         }
434       ],
435       "returns" : [
436         {
437           "name" : "",
438           "type" : "string",
439           "desc" : "The value of the style property"
440         }
441       ]
442     },
443     {
444       "name" : "getPosX",
445       "desc" : "Returns the X position of an html element",
446       "isStatic" : false,
447       "isConstructor" : false,
448       "isPrivate" : false,
449       "memberOf" : "Roo.dd.DragDropMgr",
450       "example" : "",
451       "deprecated" : "This has been deprecated: use Roo.lib.Dom.getX instead",
452       "since" : "",
453       "see" : "",
454       "params" : [
455         {
456           "name" : "el",
457           "type" : "",
458           "desc" : "the element for which to get the position",
459           "isOptional" : false
460         }
461       ],
462       "returns" : [
463         {
464           "name" : "",
465           "type" : "int",
466           "desc" : "the X coordinate"
467         }
468       ]
469     },
470     {
471       "name" : "getPosY",
472       "desc" : "Returns the Y position of an html element",
473       "isStatic" : false,
474       "isConstructor" : false,
475       "isPrivate" : false,
476       "memberOf" : "Roo.dd.DragDropMgr",
477       "example" : "",
478       "deprecated" : "This has been deprecated: use Roo.lib.Dom.getY instead",
479       "since" : "",
480       "see" : "",
481       "params" : [
482         {
483           "name" : "el",
484           "type" : "",
485           "desc" : "the element for which to get the position",
486           "isOptional" : false
487         }
488       ],
489       "returns" : [
490         {
491           "name" : "",
492           "type" : "int",
493           "desc" : "the Y coordinate"
494         }
495       ]
496     },
497     {
498       "name" : "isLocked",
499       "desc" : "Is drag and drop locked?",
500       "isStatic" : false,
501       "isConstructor" : false,
502       "isPrivate" : false,
503       "memberOf" : "Roo.dd.DragDropMgr",
504       "example" : "",
505       "deprecated" : "",
506       "since" : "",
507       "see" : "",
508       "params" : [],
509       "returns" : [
510         {
511           "name" : "",
512           "type" : "boolean",
513           "desc" : "True if drag and drop is locked, false otherwise."
514         }
515       ]
516     },
517     {
518       "name" : "getBestMatch",
519       "desc" : "Helper function for getting the best match from the list of drag\nand drop objects returned by the drag and drop events when we are\nin INTERSECT mode.  It returns either the first object that the\ncursor is over, or the object that has the greatest overlap with\nthe dragged element.",
520       "isStatic" : false,
521       "isConstructor" : false,
522       "isPrivate" : false,
523       "memberOf" : "Roo.dd.DragDropMgr",
524       "example" : "",
525       "deprecated" : "",
526       "since" : "",
527       "see" : "",
528       "params" : [
529         {
530           "name" : "dds",
531           "type" : "DragDrop[]",
532           "desc" : "The array of drag and drop objects\ntargeted",
533           "isOptional" : false
534         }
535       ],
536       "returns" : [
537         {
538           "name" : "",
539           "type" : "DragDrop",
540           "desc" : "The best single match"
541         }
542       ]
543     },
544     {
545       "name" : "getLocation",
546       "desc" : "Returns a Region object containing the drag and drop element's position\nand size, including the padding configured for it",
547       "isStatic" : false,
548       "isConstructor" : false,
549       "isPrivate" : false,
550       "memberOf" : "Roo.dd.DragDropMgr",
551       "example" : "",
552       "deprecated" : "",
553       "since" : "",
554       "see" : "",
555       "params" : [
556         {
557           "name" : "oDD",
558           "type" : "DragDrop",
559           "desc" : "the drag and drop object to get the\n                      location for",
560           "isOptional" : false
561         }
562       ],
563       "returns" : [
564         {
565           "name" : "",
566           "type" : "Roo.lib.Region",
567           "desc" : "a Region object representing the total area\n                            the element occupies, including any padding\n                            the instance is configured for."
568         }
569       ]
570     },
571     {
572       "name" : "isHandle",
573       "desc" : "Utility function to determine if a given element has been\nregistered as a drag drop handle for the given Drag Drop object.",
574       "isStatic" : false,
575       "isConstructor" : false,
576       "isPrivate" : false,
577       "memberOf" : "Roo.dd.DragDropMgr",
578       "example" : "",
579       "deprecated" : "",
580       "since" : "",
581       "see" : "",
582       "params" : [
583         {
584           "name" : "id",
585           "type" : "String",
586           "desc" : "the element id to check",
587           "isOptional" : false
588         }
589       ],
590       "returns" : [
591         {
592           "name" : "",
593           "type" : "boolean",
594           "desc" : "true if this element is a DragDrop handle, false\notherwise"
595         }
596       ]
597     },
598     {
599       "name" : "getScrollTop",
600       "desc" : "Gets the scrollTop",
601       "isStatic" : false,
602       "isConstructor" : false,
603       "isPrivate" : false,
604       "memberOf" : "Roo.dd.DragDropMgr",
605       "example" : "",
606       "deprecated" : "",
607       "since" : "",
608       "see" : "",
609       "params" : [],
610       "returns" : [
611         {
612           "name" : "",
613           "type" : "int",
614           "desc" : "the document's scrollTop"
615         }
616       ]
617     },
618     {
619       "name" : "numericSort",
620       "desc" : "Numeric array sort function",
621       "isStatic" : false,
622       "isConstructor" : false,
623       "isPrivate" : false,
624       "memberOf" : "Roo.dd.DragDropMgr",
625       "example" : "",
626       "deprecated" : "",
627       "since" : "",
628       "see" : "",
629       "params" : [],
630       "returns" : []
631     },
632     {
633       "name" : "regHandle",
634       "desc" : "Each DragDrop handle element must be registered.  This is done\nautomatically when executing DragDrop.setHandleElId()",
635       "isStatic" : false,
636       "isConstructor" : false,
637       "isPrivate" : false,
638       "memberOf" : "Roo.dd.DragDropMgr",
639       "example" : "",
640       "deprecated" : "",
641       "since" : "",
642       "see" : "",
643       "params" : [
644         {
645           "name" : "sDDId",
646           "type" : "String",
647           "desc" : "the DragDrop id this element is a handle for",
648           "isOptional" : false
649         },
650         {
651           "name" : "sHandleId",
652           "type" : "String",
653           "desc" : "the id of the element that is the drag\nhandle",
654           "isOptional" : false
655         }
656       ],
657       "returns" : []
658     },
659     {
660       "name" : "getElement",
661       "desc" : "Returns the actual DOM element",
662       "isStatic" : false,
663       "isConstructor" : false,
664       "isPrivate" : false,
665       "memberOf" : "Roo.dd.DragDropMgr",
666       "example" : "",
667       "deprecated" : "This has been deprecated: use Roo.getDom instead",
668       "since" : "",
669       "see" : "",
670       "params" : [
671         {
672           "name" : "id",
673           "type" : "String",
674           "desc" : "the id of the elment to get",
675           "isOptional" : false
676         }
677       ],
678       "returns" : [
679         {
680           "name" : "",
681           "type" : "Object",
682           "desc" : "The element"
683         }
684       ]
685     },
686     {
687       "name" : "verifyEl",
688       "desc" : "This checks to make sure an element exists and is in the DOM.  The\nmain purpose is to handle cases where innerHTML is used to remove\ndrag and drop objects from the DOM.  IE provides an 'unspecified\nerror' when trying to access the offsetParent of such an element",
689       "isStatic" : false,
690       "isConstructor" : false,
691       "isPrivate" : false,
692       "memberOf" : "Roo.dd.DragDropMgr",
693       "example" : "",
694       "deprecated" : "",
695       "since" : "",
696       "see" : "",
697       "params" : [
698         {
699           "name" : "el",
700           "type" : "HTMLElement",
701           "desc" : "the element to check",
702           "isOptional" : false
703         }
704       ],
705       "returns" : [
706         {
707           "name" : "",
708           "type" : "boolean",
709           "desc" : "true if the element looks usable"
710         }
711       ]
712     }
713   ],
714   "events" : []
715 }