title: Is there a way to create a JList in a modal dialog?
body: <p>I have a <code>JFrame</code> already visible. The user can load a saved session. </p>
  
  <p>The idea is to create a <code>JList</code>, so the user can load the chosen session  and the frame can be updated.</p>
  
  <p>The code bellow get a list of String and add them to the list.</p>
  
  <pre><code>DefaultListModel model = new DefaultListModel();
  JList list=new JList(model);
  JScrollPane pane = new JScrollPane(list);
  try {
      for (String  part : Utils.getSessions()) {
          model.addElement(part);
      }
  } catch (IOException e1) {
      e1.printStackTrace();
  }
  </code></pre>
  
  <p>The next step : display the step.</p>
  
  <p>What I found : add pane to the current frame</p>
  
  <p>My Hope: display the list in a modal dialog</p>
  
  <p>Is there a way to create a <code>JList</code> in a modal dialog?</p>