createNavigatorImage();
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 = ViewState.getInstance().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;			dx = (int)(dx/view.getScale()); 			dy = (int)(dy/view.getScale());			if (!(dx==0 && dy==0))				if (view.isSelected(hilitedObject)) 					moveSelection(dx, dy);				else					((Movable)hilitedObject).move(dx, dy);			dx = (int)((px-pressedX)/view.getScale()); 			dy = (int)((py-pressedY)/view.getScale());			if (!(dx==0 && dy==0))				if (view.isSelected(hilitedObject))				{					ComposedAction composedAction = new ComposedAction();					Enumeration selected = view.getSelectedObjects().elements();						while (selected.hasMoreElements())							composedAction.addAction(new MoveAction((Movable)selected.nextElement(), dx, dy));					UndoManager.getInstance().addAction(composedAction);				}				else					addAction(new MoveAction((Movable)hilitedObject, dx, dy));						/*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()))*/			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;			dx = (int)(Math.abs(pressedX-draggedX)/view.getScale());			dy = (int)(Math.abs(pressedY-draggedY)/view.getScale());			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;}