public void addComment(String comment){
  if (frame != null) {
    chatTab.addComment(comment);
  }
  if (tabbedPane.getSelectedIndex() == 2) {
    editorTab.displayComment(comment);
  }
}

public void addComment ( String comment ) { if ( frame != null ) { chatTab . addComment ( comment ) ; } if ( tabbedPane . getSelectedIndex ( ) == 2 ) { editorTab . displayComment ( comment ) ; } }
adds a comment to the chat window
