private void removeSelectedObjects() {
		int n = model.getNumberOfParticles();
		List<Integer> list = new ArrayList<Integer>();
		for (int k = 0; k < n; k++) {
			if (model.getParticle(k).isSelected())
				list.add(k);
		}
		if (model instanceof MolecularModel) {
			if (!list.isEmpty())
				((AtomisticView) view).removeMarkedAtoms(list);
			MolecularModel mm = (MolecularModel) model;
			boolean b = false;
			synchronized (mm.bonds.getSynchronizationLock()) {
				for (Iterator it = mm.bonds.iterator(); it.hasNext();) {
					RadialBond rb = (RadialBond) it.next();
					if (rb.isSelected()) {
						it.remove();
						rb.removeAttachedLayeredComponents();
						b = true;
					}
				}
			}
			synchronized (mm.bends.getSynchronizationLock()) {
				for (Iterator it = mm.bends.iterator(); it.hasNext();) {
					if (((AngularBond) it.next()).isSelected())
						it.remove();
				}
			}
			mm.removeGhostAngularBonds();
			if (b) {
				mm.view.bondChanged(null);
				mm.updateBondTable();
				MoleculeCollection.sort(mm);
			}
			// mm.view.removeSelectedComponent();
		} else if (model instanceof MesoModel) {
			((MesoView) view).removeMarkedParticles(list);
		}
		if (!model.obstacles.isEmpty()) {
			RectangularObstacle obs = null;
			synchronized (model.obstacles.getSynchronizationLock()) {
				for (Iterator it = model.obstacles.iterator(); it.hasNext();) {
					obs = (RectangularObstacle) it.next();
					if (obs.isSelected())
						it.remove();
				}
			}
		}
		view.removeAllSelectedLayeredComponents();
		view.repaint();
	}