if (notYetDragged) break;
public void mouseReleased(MouseEvent e) {	ViewState view = ViewState.getInstance();	int px = e.getX()-view.getX0();	int py = e.getY()-view.getY0();	//boolean leftButtonPush = (e.getModifiers() & InputEvent.BUTTON1_MASK) != 0;	//boolean rightButtonPush  = (e.getModifiers() & InputEvent.BUTTON3_MASK) != 0;	//System.out.println("mouseReleased("+leftButtonPush+","+rightButtonPush+")");	VisibleObject hilitedObject = view.getHilitedObject();	//System.out.println("hilited: "+hilitedObject);	switch (mouseOperation) {		case ORIGIN_MOVE : //System.out.println("Released: ORIGIN_MOVE");			restoreCursor();			forceRedraw=true;			repaint(); // jic			break;						case OBJECT_MOVE : {//System.out.println("Released: OBJECT_MOVE");			createNavigatorImage();			int dx = px-draggedX;			int dy = py-draggedY;			if (fastMove) {				dx = draggedX-pressedX;				dy = draggedY-pressedY;				fastMove=false;			}									double scale = view.getScale();			dx = (int)(dx/scale); 			dy = (int)(dy/scale);			if (Settings.getInstance().getSnapToGrid())			{				dx -= dx % Constants.GRID_SIZE;				dy -= dy % Constants.GRID_SIZE;			}						if (!(dx==0 && dy==0))				if (view.isSelected(hilitedObject)) 					moveSelection(dx, dy);				else					((Movable)hilitedObject).move(dx, dy);						// create undo actions			if (view.isSelected(hilitedObject))			{				ComposedAction composedAction = new ComposedAction();				Enumeration selected = view.getSelectedObjects().elements();					while (selected.hasMoreElements())					{						VisibleObject o = (VisibleObject)selected.nextElement();						composedAction.addAction(new MoveAction((Movable)o,													o.getX() - o.getMarkedX(),													o.getY() - o.getMarkedY()));					}				UndoManager.getInstance().addAction(composedAction);			}			else			{				addAction(new MoveAction((Movable)hilitedObject, 							hilitedObject.getX() - hilitedObject.getMarkedX(),							hilitedObject.getY() - hilitedObject.getMarkedY()));			}						/*ViewState.getInstance().setAsHilited(null);					int cx = e.getX()-view.getX0();			int cy = e.getY()-view.getY0();			if (viewGroup.hiliteComponentsCheck(cx+view.getRx(), cy+view.getRy()))*/						fastDrawing=false;			forceRedraw=true;			//alsoDrawHilitedOnce=true;			repaint();			break;}					case OBJECT_SELECTION : //System.out.println("Released: OBJECT_SELECTION");					fastDrawing=false;			selectArea(pressedX, pressedY, 			   		   draggedX, draggedY); 		    repaint();		    break;		case ZOOM_SELECTION :{ //System.out.println("Released: ZOOM_SELECTION");					fastDrawing=false;						double scale = view.getScale();			int dx = (int)(Math.abs(pressedX-draggedX)/scale);			int dy = (int)(Math.abs(pressedY-draggedY)/scale);						if ((dx>Constants.RECORD_HEIGHT) &&	(dy>Constants.RECORD_HEIGHT))				zoomArea(pressedX, pressedY, 				   		 draggedX, draggedY); 		    repaint();		    break;}		    		case LINK_OPERATION ://System.out.println("Released: LINK_OPERATION");			fastDrawing=false;			// link !!!			repaint();			break;			}	//System.out.println(" hilited: "+hilitedObject);	mouseOperation = NO_OPERATION;}