sessionPane.getComponent(sessionPane.getSelectedIndex()).requestFocus();
   private void nextSession() {      int index = sessionPane.getSelectedIndex();      sessionPane.setForegroundAt(index,Color.black);      sessionPane.setIconAt(index,unfocused);      if (index < sessionPane.getTabCount() - 1) {         sessionPane.setSelectedIndex(++index);         sessionPane.setForegroundAt(index,Color.blue);         sessionPane.setIconAt(index,focused);      }      else {         sessionPane.setSelectedIndex(0);         sessionPane.setForegroundAt(0,Color.blue);         sessionPane.setIconAt(0,focused);      }   }