Bug 210338 [Regression]NPE throws out when drag the another dimension into the row area of crosstab[1102]
Description: [Regression]NPE throws out when drag the another dimension into the row area of crosstab[1102] Build number: 2.3.0.v20071120-0800 Steps to reproduce: 1, New a cube with multiple dimensions 2, New a crosstab 3, Drag one dimension from cube to crosstab's row area 4, Drag another dimension from cube to the same area nearby the former dimension Expected result: After step4, the second dimension has been dragged into the same area successully Actual result: NPE throws out and failed to drag Error log: java.lang.NullPointerException at org.eclipse.birt.report.item.crosstab.internal.ui.editors.editpolicies.CrosstabCellFlowLayoutEditPolicy.getCreateCommand(CrosstabCellFlowLayoutEditPolicy.java:84) at org.eclipse.gef.editpolicies.LayoutEditPolicy.getCommand(LayoutEditPolicy.java:199) at org.eclipse.birt.report.designer.internal.ui.editors.schematic.editpolicies.ReportFlowLayoutEditPolicy.getCommand(ReportFlowLayoutEditPolicy.java:208) at org.eclipse.gef.editparts.AbstractEditPart.getCommand(AbstractEditPart.java:473) at org.eclipse.birt.report.item.crosstab.internal.ui.dnd.DimensionHandleDropAdapter.performDrop(DimensionHandleDropAdapter.java:171) at org.eclipse.birt.report.designer.internal.ui.dnd.DNDService.performDrop(DNDService.java:160) at org.eclipse.birt.report.designer.internal.ui.dnd.DNDService.performDrop(DNDService.java:146) at org.eclipse.birt.report.designer.internal.ui.palette.ReportTemplateTransferDropTargetListener.handleDrop(ReportTemplateTransferDropTargetListener.java:115) at org.eclipse.gef.dnd.AbstractTransferDropTargetListener.drop(AbstractTransferDropTargetListener.java:171) at org.eclipse.jface.util.DelegatingDropAdapter$3.run(DelegatingDropAdapter.java:211) at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37) at org.eclipse.core.runtime.Platform.run(Platform.java:857)
xtab/org.eclipse.birt.report.item.crosstab.ui/src/org/eclipse/birt/report/item/crosstab/internal/ui/editors/editpolicies/CrosstabCellFlowLayoutEditPolicy.java
Object dragObject = ( (Object[]) template )[0];
				if ( dragObject instanceof DimensionHandle
						|| dragObject instanceof MeasureHandle )
				{
					isCrossTabElement = true;
				}
			}
		}
		if ( isCrossTabElement )
		{
			Transposer transposer = new Transposer( );
			transposer.setEnabled( !isHorizontal( ) );
			Rectangle r = transposer.t( getAbsoluteClientBounds( (GraphicalEditPart) getHost( ) ) );
			Point p = transposer.t( getLocationFromRequest( request ) );
			boolean before = p.x <= r.x + ( r.width / 2 );
			Point p1 = new Point( before ? r.x : r.x + r.width, r.y - 2 );
			p1 = transposer.t( p1 );
			Point p2 = new Point( before ? r.x : r.x + r.width, r.y
					+ r.height
					+ 7 );
			p2 = transposer.t( p2 );
			setTargetFeedbackPoints( p1, p2 );
		}
		else
		{
			super.showLayoutTargetFeedback( request );
		}
	}
}