public int getCursor(MouseEvent me) {

		Component c = me.getComponent();
		int w = c.getWidth();
		int h = c.getHeight();

		for (int i = 0; i < locations.length; i++) {
			Rectangle rect = getRectangle(0, 0, w, h, locations[i]);
			if (rect.contains(me.getPoint()))
				return cursors[i];
		}

		return Cursor.MOVE_CURSOR;
	}