public DrawableItem getItemAt(Point p) {

        DrawableItem item = null;

        for (DrawableItem i : items) {
            if (i instanceof Panel) {
               // int[] ind = {0};
                Point anchor = ((Panel) i).getKnobContainingPoint(p);

                if (dic.contains(i, p) || anchor != null) {
                    ((Panel) i).setAnchor(anchor);
                    //setAnchorForSelected(i, allSelected, ind);
                    item = i;
                    break;
                }
            }
        }
        return item;
    }