return;
}
}
final AttachmentList<BoardAttachment> boardAttachmentList = selectedMessage.getAttachmentsOfTypeBoard();
for( final int element : selectedRows ) {
final Board fbo = boardAttachmentList.get(element).getBoardObj();
final String boardName = fbo.getName();
// search board in exising boards list
final Board board = mainFrame.getFrostMessageTab().getTofTreeModel().getBoardByName(boardName);
//ask if we already have the board
if (board != null) {
if (JOptionPane.showConfirmDialog(
this,
"You already have a board named " + boardName + ".\n" +
"Are you sure you want to add this one over it?",
"Board already exists",
JOptionPane.YES_NO_OPTION) != 0)
{
continue; // next row of table / next attached board
} else {
// change existing board keys to keys of new board
board.setPublicKey(fbo.getPublicKey());
board.setPrivateKey(fbo.getPrivateKey());
mainFrame.updateTofTree(board);
}
} else {
// its a new board
if(targetFolder == null) {