@Override
    public void mousePressed(MouseEvent e) {
        if(myCardList.size() > 0){
            
            if(myCardGap > 0) clickedCard = e.getY() / myCardGap;
            else clickedCard = 0;
            
            if(clickedCard >= myCardList.size()) clickedCard = myCardList.size() - 1;
            if(this.getType() == FoundationType.DISCARD) clickedCard = myCardList.size() - 1;
            else if(this.getType() == FoundationType.SUIT) clickedCard = myCardList.size() - 1;
            
            if(myCardList.get(clickedCard).getOrientation() == CardOrientation.FACEUP){
                dragStack = new CardStack(myCardList.subList(clickedCard, myCardList.size()));
                myCardList.removeAll(dragStack.getCardList());
                this.getParent().add(dragStack);
                this.getParent().setComponentZOrder(dragStack, 0);
                dragStartX = e.getX();
                dragStartY = e.getY();
                dragStack.setLocation(this.getX(), this.getY()  + (clickedCard * myCardGap));
                isDragging = true;
                this.getParent().repaint();
            }
        }
    }