Hi,
I'm trying to use the dragTarget property on a CSS driven Button onto which I've added a children Img
component to be used as a drag handle. I use 'parent' as the value for the dragTarget property.
The problem is that the drag "hot spot" is not overlaid at the right place on the underlying button.
I can only drag if I grip the extreme right portion (almost outside) of the parent component, instead
of gripping the area the children Img component is covering.
Here's the code to reproduce:
We're getting this behavior using ISC version 8 nightly from 07/07, both under FF 3.6.6 (Mac) and IE 8 (Win).
Any idea how can I get this to work?
Thanking you again for your assistance.
Kind regards,
I'm trying to use the dragTarget property on a CSS driven Button onto which I've added a children Img
component to be used as a drag handle. I use 'parent' as the value for the dragTarget property.
The problem is that the drag "hot spot" is not overlaid at the right place on the underlying button.
I can only drag if I grip the extreme right portion (almost outside) of the parent component, instead
of gripping the area the children Img component is covering.
Here's the code to reproduce:
Code:
var btn = IButton.create ({ layoutAlign : 'center', height : 30, width : '100%', showRollOver : false, showDown : false, canFocus : true, showFocus : true, dragHandleWidth : 19, dragHandleHeight : 16, title : 'My button', click : 'alert(123)', children : [ Img.create ({ src : 'dragHandle.png', imageType : 'normal', width : this.dragHandleWidth, imageWidth : this.dragHandleWidth, height : this.dragHandleHeight, imageHeight : this.dragHandleHeight, canFocus : true, canHover : true, canDrag : true, canDrop : true, canDragReposition : true, dragTarget : 'parent', dragAppearance : 'target' }) ], resized : function (deltaX, deltaY) { this.Super('resized', arguments); if (this.children && this.children.length > 0) { this.children[0].setLeft(this.getInnerWidth() - this.dragHandleWidth - 4); this.children[0].setTop((this.getInnerHeight() - this.dragHandleHeight) / 2); } } });
Any idea how can I get this to work?
Thanking you again for your assistance.
Kind regards,
Comment