View | Details | Raw Unified | Return to bug 146692 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/eclipse/gmf/runtime/diagram/ui/tools/ConnectionCreationTool.java (+16 lines)
Lines 27-32 Link Here
27
import org.eclipse.gef.requests.CreateConnectionRequest;
27
import org.eclipse.gef.requests.CreateConnectionRequest;
28
import org.eclipse.gef.ui.parts.ScrollingGraphicalViewer;
28
import org.eclipse.gef.ui.parts.ScrollingGraphicalViewer;
29
import org.eclipse.gmf.runtime.diagram.core.preferences.PreferencesHint;
29
import org.eclipse.gmf.runtime.diagram.core.preferences.PreferencesHint;
30
import org.eclipse.gmf.runtime.diagram.ui.editparts.CompartmentEditPart;
31
import org.eclipse.gmf.runtime.diagram.ui.editparts.DiagramEditPart;
30
import org.eclipse.gmf.runtime.diagram.ui.editparts.IDiagramPreferenceSupport;
32
import org.eclipse.gmf.runtime.diagram.ui.editparts.IDiagramPreferenceSupport;
31
import org.eclipse.gmf.runtime.diagram.ui.editparts.IGraphicalEditPart;
33
import org.eclipse.gmf.runtime.diagram.ui.editparts.IGraphicalEditPart;
32
import org.eclipse.gmf.runtime.diagram.ui.editparts.IPrimaryEditPart;
34
import org.eclipse.gmf.runtime.diagram.ui.editparts.IPrimaryEditPart;
Lines 78-83 Link Here
78
		.getDefault(), DiagramUIPluginImages.DESC_NO_CONNECTION_CURSOR_SOURCE
80
		.getDefault(), DiagramUIPluginImages.DESC_NO_CONNECTION_CURSOR_SOURCE
79
		.getImageData(), DiagramUIPluginImages.DESC_NO_CONNECTION_CURSOR_MASK
81
		.getImageData(), DiagramUIPluginImages.DESC_NO_CONNECTION_CURSOR_MASK
80
		.getImageData(), 0, 0);
82
		.getImageData(), 0, 0);
83
	
84
	static private Cursor CURSOR_TARGET_MENU = new Cursor(null, SWT.CURSOR_HAND);
81
85
82
	/**
86
	/**
83
	 * Creates a new ConnectionCreationTool, the elementTypeInfo and
87
	 * Creates a new ConnectionCreationTool, the elementTypeInfo and
Lines 436-439 Link Here
436
		return null;
440
		return null;
437
	}
441
	}
438
442
443
	/* (non-Javadoc)
444
	 * @see org.eclipse.gef.tools.AbstractConnectionCreationTool#calculateCursor()
445
	 */
446
	protected Cursor calculateCursor() {
447
		EditPart ep = getTargetEditPart();
448
		if (ep instanceof DiagramEditPart || ep instanceof CompartmentEditPart)
449
			return CURSOR_TARGET_MENU;
450
		return super.calculateCursor();
451
	}
452
	
453
	
454
439
}
455
}

Return to bug 146692