protected void do_lblImage_mousePressed(MouseEvent e) {

		lastX = e.getX();
		lastY = e.getY();

		rect = lblImage.getRect();
		if (e.getX() >= rect.getX()
				&& e.getX() <= rect.getX() + rect.getWidth()
				&& e.getY() == rect.getY()) {
			drag = true;
		}

		if ((e.getX() == rect.getX() + rect.getWidth() && e.getY() >= rect.getY() && e.getY() <= rect.getY() + rect.getHeight()) || 
			(e.getX() >= rect.getX() && e.getX() <= rect.getX() + rect.getWidth() && e.getY() == rect.getY() + rect.getHeight())) {

			resize = true;
		}
	}