public boolean showPreviousNotification(){
  int i=getSelectedIndex();
  if (i != -1 && i > 0) {
    model.setSelectedItem(model.getElementAt(i - 1));
    return true;
  }
  return false;
}

public boolean showPreviousNotification ( ) { int i = getSelectedIndex ( ) ; if ( i != - 1 && i > 0 ) { model . setSelectedItem ( model . getElementAt ( i - 1 ) ) ; return true ; } return false ; }
scrolls to the previous notification .
