title: SWT Eclipse Combo Event
body: <p>I'm doing an Eclipse plugin with an Form MultiPage Editor.</p>
  
  <p>On one of the pages I have split the page in two halves and are generating the pages in two different classes. In the FormPage im adding these two halves and everything is fine.</p>
  
  <p>Now to my <strong>problem</strong>: On each side I have one Combo Box which is set to READ_ONLY. The Problem is that the Items of the second Combo are dependent on the selected Item from the first Combo.</p>
  
  <p>Small mockup of my Code:</p>
  
  <pre><code>//something 
  
  new FirstHalf(Stuff);
  
  new SecondHalf(OtherStuff);
  
  ----------
  public int firstComboIndex = 0;
  
  public FirstHalf(Stuff){
  
      Combo firstCombo = new Combo(SomeClient, SWT.READ_ONLY);
  
      String[] itemsArray = new String[stuff];
  
      firstCombo.setItems(itemsArray);
  
      firstCombo.setText(itemsArray[firstComboIndex]);
  
  }
  
  ----------
  public int secondComboIndex = 0;
  
  public SecondHalf(Stuff){
  
      Combo secondCombo = new Combo(SomeOtherClient, SWT.READ_ONLY);
  
      String[] array1 = new String[stuff];
      String[] array2 = new String[stuff];
      String[] array3 = new String[stuff];
  
      String[][] arrays = { array1, array2, array3};
  
      String[] secondItemsArray = new String[arrays[firstComboIndex];
  
      secondCombo.setItems(secondItemsArray);
  
      secondCombo.setText(secondItemsArray[secondComboIndex]);
  
  }
  </code></pre>
  
  <p>Now how do I do it so, that when ever the first combo choice is changed. The second changes too.</p>