From: Antoine Q. <an...@gr...> - 2001-09-17 13:49:51
|
Hey, Just though of a new use for getBBox(). For the "drag.es" module, an invisible rectangle is created to prevent unwanted "mouseout" events to happen. We could actually do with something smaller than the full-composition rectangle by just calling getBBox() on the dragged element and create an invisible rectangle that would be 110% the size of the bounding box. That would be cleaner I suppose. The invisible rectangle would have to be dragged though, but I don't reckon it's too much hassle. ---- And this is a little trick to prevent the Adobe contectual menu to appear on right-click. This is pretty pointless as is, but one could implement a completely new draggable-contextual menu on right click! This is going on graougraou.com's new site. function mouse_down(evt) { if(evt.getButton() == 2) { evt.preventDefault(); // right-click code } antoine |