From: Alan Knowles Date: Wed, 7 Apr 2021 09:46:19 +0000 (+0800) Subject: Changed docs/json/roodata.jsondocs/src/Roo_bootstrap_Card.js.htmldocs/symbols/Roo... X-Git-Url: http://git.roojs.org/?p=roojs1;a=commitdiff_plain;h=607f8469f748c1ac685316b4e09f0609b01d1b53 Changed docs/json/roodata.jsondocs/src/Roo_bootstrap_Card.js.htmldocs/symbols/Roo.bootstrap.Card.json --- diff --git a/docs/json/roodata.json b/docs/json/roodata.json index d4407dad73..de79c89dc8 100644 --- a/docs/json/roodata.json +++ b/docs/json/roodata.json @@ -19862,6 +19862,13 @@ "sig" : "function (_self)\n{\n\n}", "memberOf" : "Roo.Component" }, + { + "name" : "cardover", + "type" : "function", + "desc" : "When a card element is dragged over ready to drop (return false to block dropable)", + "sig" : "function (_self, data)\n{\n\n}", + "memberOf" : "" + }, { "name" : "childrenrendered", "type" : "function", @@ -20034,7 +20041,7 @@ { "name" : "getTargetFromEvent", "type" : "function", - "desc" : "Part of the Roo.dd.DropZone interface. If no target node is found, the\n whole Element becomes the target, and this causes the drop gesture to append.", + "desc" : "Part of the Roo.dd.DropZone interface. If no target node is found, the\n whole Element becomes the target, and this causes the drop gesture to append.\n\n Returns an object:\n {\n \n position : 'below' or 'above'\n card : relateive to card OBJECT (or true for no cards listed)\n items_n : relative to nth item in list\n card_n : relative to nth card in list\n }", "sig" : "()\n{\n\n}", "static" : false, "memberOf" : "" diff --git a/docs/src/Roo_bootstrap_Card.js.html b/docs/src/Roo_bootstrap_Card.js.html index 2aa75bad5b..10e645d97a 100644 --- a/docs/src/Roo_bootstrap_Card.js.html +++ b/docs/src/Roo_bootstrap_Card.js.html @@ -80,11 +80,18 @@ /** * @event rotate * When a element a card is rotate - * @param {Roo.bootstrap.Element} this + * @param {Roo.bootstrap.Card} this * @param {Roo.Element} n the node being dropped? * @param {Boolean} rotate status */ - 'rotate' : true + 'rotate' : true, + /** + * @event cardover + * When a card element is dragged over ready to drop (return false to block dropable) + * @param {Roo.bootstrap.Card} this + * @param {Object} data from dragdrop + */ + 'cardover' : true }); }; @@ -437,6 +444,17 @@ /** * Part of the Roo.dd.DropZone interface. If no target node is found, the * whole Element becomes the target, and this causes the drop gesture to append. + * + * Returns an object: + * { + + position : 'below' or 'above' + card : relateive to card OBJECT (or true for no cards listed) + items_n : relative to nth item in list + card_n : relative to nth card in list + } + * + * */ getTargetFromEvent : function(e, dragged_card_el) { @@ -531,6 +549,10 @@ Roo.log(['getTargetFromEvent', target_info ]); + if (this.fireEvent('cardover', this, [ data ]) === false) { + return false; + } + this.dropPlaceHolder('show', target_info,data); return false; @@ -557,8 +579,6 @@ - - this.acceptCard(data.source, info.position, info.card, info.items_n); return true; diff --git a/docs/symbols/Roo.bootstrap.Card.json b/docs/symbols/Roo.bootstrap.Card.json index 5081de51cb..814452e3ae 100644 --- a/docs/symbols/Roo.bootstrap.Card.json +++ b/docs/symbols/Roo.bootstrap.Card.json @@ -522,7 +522,7 @@ }, { "name" : "getTargetFromEvent", - "desc" : "Part of the Roo.dd.DropZone interface. If no target node is found, the\n whole Element becomes the target, and this causes the drop gesture to append.", + "desc" : "Part of the Roo.dd.DropZone interface. If no target node is found, the\n whole Element becomes the target, and this causes the drop gesture to append.\n\n Returns an object:\n {\n \n position : 'below' or 'above'\n card : relateive to card OBJECT (or true for no cards listed)\n items_n : relative to nth item in list\n card_n : relative to nth card in list\n }", "isStatic" : false, "isConstructor" : false, "isPrivate" : false, @@ -1168,7 +1168,7 @@ "params" : [ { "name" : "this", - "type" : "Roo.bootstrap.Element", + "type" : "Roo.bootstrap.Card", "desc" : "", "isOptional" : false }, @@ -1223,6 +1223,30 @@ ], "returns" : [] }, + { + "name" : "cardover", + "desc" : "When a card element is dragged over ready to drop (return false to block dropable)", + "memberOf" : "Roo.bootstrap.Card", + "example" : "", + "deprecated" : "", + "since" : "", + "see" : "", + "params" : [ + { + "name" : "this", + "type" : "Roo.bootstrap.Card", + "desc" : "", + "isOptional" : false + }, + { + "name" : "data", + "type" : "Object", + "desc" : "from dragdrop", + "isOptional" : false + } + ], + "returns" : [] + }, { "name" : "childrenrendered", "desc" : "Fires when the children have been rendered..",