updateUI();
updatePanel();
	public synchronized void setPartList(PartListDO newPartListDO, Integer newId) {		try {			if (newPartListDO == null || newId == null){				partListDO = null;				lineImage = null;				image = null;				savedMouseEvent = null;				updateUI();				return;			}			boolean idChanged = false;			if (id == null){				idChanged = true;				id = newId;			}			if (id.longValue() != newId.longValue()){				idChanged = true;			}			if (idChanged){				id = newId;				if (partListDO != null){					partListDO.removeAllParts();				}			}			else if (partListDO != null && newPartListDO != null){				Part[] parts = partListDO.getParts();				Part[] newParts = newPartListDO.getParts();				if (parts.length == newParts.length){					boolean sameParts = true;					for (int i=0; i<parts.length; i++){						if (!parts[i].equals(newParts[i])){							sameParts = false;							break;						}					}					if(sameParts){						insertSources(partListDO, lineImage);						updateUI();						return;					}				}			}			partListDO = newPartListDO;			height = (int) getSize().getHeight();			width = (int) getSize().getWidth();			if (partListDO != null && partListDO.getParts().length > 0) {				Part[] parts = partListDO.getParts();				zeilenHoehe = 15;				int zeilen = height / zeilenHoehe;				miniFile = false;				pixelSize = (int) (partListDO.getGroesse() / (zeilen * width));				if (pixelSize == 0) {					pixelSize = (int) ((zeilen * width) / partListDO							.getGroesse());					miniFile = true;				}				lineImage = new BufferedImage(width * zeilen,						15, BufferedImage.TYPE_INT_ARGB);				Graphics graphics = lineImage.getGraphics();				int obenLinks = 0;				int breite = 0;				fertigSeit = -1;				for (int i = 0; i < parts.length - 1; i++) {					drawPart(							false,							(partListDO.getPartListType() == PartListDO.MAIN_PARTLIST),							graphics, pixelSize, parts[i].getType(),							zeilenHoehe, parts[i].getFromPosition(),							parts[i + 1].getFromPosition());				}				drawPart(						true,						(partListDO.getPartListType() == PartListDO.MAIN_PARTLIST),						graphics, pixelSize, parts[parts.length - 1]								.getType(), zeilenHoehe,						parts[parts.length - 1].getFromPosition(),						partListDO.getGroesse());				BufferedImage imgWithSources = insertSources(partListDO, lineImage);				if (savedMouseEvent != null) {					processMouseMotionEvent(savedMouseEvent);				}			} else {				image = null;				savedMouseEvent = null;			}		} catch (Exception e) {			e.printStackTrace();			partListDO = null;			lineImage = null;			image = null;			savedMouseEvent = null;			if (logger.isEnabledFor(Level.DEBUG)) {				logger.debug(ApplejuiceFassade.ERROR_MESSAGE, e);			}		}		updateUI();	}