Author: sdzmitrovich
Date: 2008-03-03 08:05:49 -0500 (Mon, 03 Mar 2008)
New Revision: 6668
Modified:
trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeSelectionBuilder.java
Log:
http://jira.jboss.com/jira/browse/JBIDE-1468
Modified:
trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeSelectionBuilder.java
===================================================================
---
trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeSelectionBuilder.java 2008-03-03
10:52:13 UTC (rev 6667)
+++
trunk/vpe/plugins/org.jboss.tools.vpe/src/org/jboss/tools/vpe/editor/VpeSelectionBuilder.java 2008-03-03
13:05:49 UTC (rev 6668)
@@ -1158,10 +1158,20 @@
nsISelection selection =
visualSelectionController.getSelection(nsISelectionController.SELECTION_NORMAL);
nsIDOMNode visualNode = VisualDomUtil.getTargetNode(mouseEvent);
- if (visualNode != null && visualNode.getNodeType() == Node.ELEMENT_NODE
&&
- (HTML.TAG_INPUT.equalsIgnoreCase(visualNode.getNodeName()) ||
HTML.TAG_BUTTON.equalsIgnoreCase(visualNode.getNodeName()) ||
HTML.TAG_SELECT.equalsIgnoreCase(visualNode.getNodeName())) &&
- !selection.containsNode(visualNode, false) &&
visualBuilder.canInnerDrag((nsIDOMElement)visualNode.queryInterface(nsIDOMElement.NS_IDOMELEMENT_IID)))
{
- return (nsIDOMElement)visualNode.queryInterface(nsIDOMElement.NS_IDOMELEMENT_IID);
+ //FIX FOR JBIDE-1468 added by Sergey Dzmitrovich
+ if (visualNode != null
+ && visualNode.getNodeType() == Node.ELEMENT_NODE
+ && (HTML.TAG_INPUT.equalsIgnoreCase(visualNode.getNodeName())
+ || HTML.TAG_OPTION.equalsIgnoreCase(visualNode
+ .getNodeName())
+ || HTML.TAG_BUTTON.equalsIgnoreCase(visualNode
+ .getNodeName()) || HTML.TAG_SELECT
+ .equalsIgnoreCase(visualNode.getNodeName()))
+ /*&& !selection.containsNode(visualNode, false)*/
+ && visualBuilder.canInnerDrag((nsIDOMElement) visualNode
+ .queryInterface(nsIDOMElement.NS_IDOMELEMENT_IID))) {
+ return (nsIDOMElement) visualNode
+ .queryInterface(nsIDOMElement.NS_IDOMELEMENT_IID);
}
return null;
}