Program: 148312
Project: 148312
Buggy source:
@Override protected void createFormContent(IManagedForm managedForm){
  try {
    managedForm.getForm().setText(this.getTitle());
    FormToolkit toolkit=WidgetFactory.getWidgetFactory();
    Composite composite=managedForm.getForm().getBody();
    composite.setLayout(new GridLayout(9,false));
    Label fromLabel=toolkit.createLabel(composite,"String_Node_Str",SWT.NULL);
    fromLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    CalendarSelectWidget fromCalendar=new CalendarSelectWidget(toolkit,composite,true);
    fromText=fromCalendar.getText();
    fromText.addKeyListener(new KeyListener(){
      public void keyPressed(      KeyEvent e){
      }
      public void keyReleased(      KeyEvent e){
        if ((e.stateMask == 0) && (e.character == SWT.CR)) {
          DataClusterBrowserMainPage.this.resultsViewer.setInput(getResults(true));
          readjustViewerHeight();
        }
      }
    }
);
    Label toLabel=toolkit.createLabel(composite,"String_Node_Str",SWT.NULL);
    toLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    CalendarSelectWidget toCalendar=new CalendarSelectWidget(toolkit,composite,false);
    toText=toCalendar.getText();
    toText.addKeyListener(keylistener);
    Label conceptLabel=toolkit.createLabel(composite,"String_Node_Str",SWT.NULL);
    conceptLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    conceptCombo=new Combo(composite,SWT.READ_ONLY | SWT.DROP_DOWN | SWT.MULTI);
    conceptCombo.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    ((GridData)conceptCombo.getLayoutData()).widthHint=180;
    conceptCombo.addKeyListener(keylistener);
    Button bSearch=toolkit.createButton(composite,"String_Node_Str",SWT.CENTER);
    bSearch.setImage(ImageCache.getCreatedImage(EImage.BROWSE.getPath()));
    bSearch.setToolTipText("String_Node_Str");
    bSearch.setLayoutData(new GridData(SWT.NONE,SWT.CENTER,false,false,1,1));
    bSearch.addListener(SWT.Selection,new Listener(){
      public void handleEvent(      Event event){
        pageToolBar.reset();
        doSearch();
      }
    }
);
    Label keyLabel=toolkit.createLabel(composite,"String_Node_Str",SWT.NULL);
    keyLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    keyText=toolkit.createText(composite,"String_Node_Str",SWT.BORDER | SWT.MULTI);
    keyText.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,5,1));
    keyText.addKeyListener(keylistener);
    Label descriptionLabel=toolkit.createLabel(composite,"String_Node_Str",SWT.NULL);
    descriptionLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    searchText=toolkit.createText(composite,"String_Node_Str",SWT.BORDER | SWT.MULTI);
    searchText.setLayoutData(new GridData(SWT.FILL,SWT.FILL,true,false,1,1));
    searchText.addKeyListener(keylistener);
    checkFTSearchButton=toolkit.createButton(composite,"String_Node_Str",SWT.CHECK);
    checkFTSearchButton.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    Label fill=toolkit.createLabel(composite,"String_Node_Str",SWT.NULL);
    fill.setLayoutData(new GridData(SWT.RIGHT,SWT.CENTER,false,false,8,1));
    showTaskIdCB=toolkit.createButton(composite,"String_Node_Str",SWT.CHECK);
    showTaskIdCB.setLayoutData(new GridData(SWT.LEFT,SWT.CENTER,false,false,1,1));
    pageToolBar=new PageingToolBar(composite);
    pageToolBar.getComposite().setLayoutData(new GridData(SWT.FILL,SWT.TOP,true,false,9,1));
    pageToolBar.getComposite().setVisible(false);
    pageToolBar.setPageingListener(this);
    int style=SWT.MULTI | SWT.BORDER | SWT.H_SCROLL| SWT.FULL_SELECTION| SWT.HIDE_SELECTION;
    resultsViewer=new TableViewer(composite,style);
    initTable(resultsViewer.getTable());
    resultsViewer.getControl().setLayoutData(new GridData(SWT.FILL,SWT.FILL,true,true,9,1));
    ((GridData)resultsViewer.getControl().getLayoutData()).heightHint=DEFAULT_VIEWER_HEIGHT;
    resultsViewer.setContentProvider(new ArrayContentProvider());
    resultsViewer.setLabelProvider(new ClusterTableLabelProvider());
    resultsViewer.addDoubleClickListener(new IDoubleClickListener(){
      public void doubleClick(      DoubleClickEvent event){
        resultsViewer.setSelection(event.getSelection());
        try {
          new EditItemAction(DataClusterBrowserMainPage.this.getSite().getShell(),resultsViewer).run();
        }
 catch (        Exception e) {
          MessageDialog.openError(DataClusterBrowserMainPage.this.getSite().getShell(),"String_Node_Str","String_Node_Str" + e.getClass().getName() + "String_Node_Str"+ e.getLocalizedMessage());
        }
      }
    }
);
    hookKeyboard();
    hookContextMenu();
    managedForm.reflow(true);
    searchText.setFocus();
    toolkit.adapt(composite);
  }
 catch (  Exception e) {
    log.error(e.getMessage(),e);
  }
}

Fixed version (ground truth):
@Override protected void createFormContent(IManagedForm managedForm){
  try {
    managedForm.getForm().setText(this.getTitle());
    FormToolkit toolkit=WidgetFactory.getWidgetFactory();
    Composite composite=managedForm.getForm().getBody();
    composite.setLayout(new GridLayout());
    Composite compFirstLine=toolkit.createComposite(composite,SWT.NONE);
    compFirstLine.setLayoutData(new GridData(SWT.FILL,SWT.NONE,true,false));
    compFirstLine.setLayout(new GridLayout(9,false));
    Label fromLabel=toolkit.createLabel(compFirstLine,"String_Node_Str",SWT.NULL);
    fromLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    CalendarSelectWidget fromCalendar=new CalendarSelectWidget(toolkit,compFirstLine,true);
    fromText=fromCalendar.getText();
    fromText.addKeyListener(new KeyListener(){
      public void keyPressed(      KeyEvent e){
      }
      public void keyReleased(      KeyEvent e){
        if ((e.stateMask == 0) && (e.character == SWT.CR)) {
          DataClusterBrowserMainPage.this.resultsViewer.setInput(getResults(true));
          readjustViewerHeight();
        }
      }
    }
);
    Label toLabel=toolkit.createLabel(compFirstLine,"String_Node_Str",SWT.NULL);
    toLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    CalendarSelectWidget toCalendar=new CalendarSelectWidget(toolkit,compFirstLine,false);
    toText=toCalendar.getText();
    toText.addKeyListener(keylistener);
    Label conceptLabel=toolkit.createLabel(compFirstLine,"String_Node_Str",SWT.NULL);
    conceptLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    conceptCombo=new Combo(compFirstLine,SWT.READ_ONLY | SWT.DROP_DOWN | SWT.MULTI);
    conceptCombo.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,true,false,1,1));
    conceptCombo.addKeyListener(keylistener);
    Button bSearch=toolkit.createButton(compFirstLine,"String_Node_Str",SWT.CENTER);
    bSearch.setImage(ImageCache.getCreatedImage(EImage.BROWSE.getPath()));
    bSearch.setToolTipText("String_Node_Str");
    bSearch.setLayoutData(new GridData(SWT.LEFT,SWT.CENTER,false,false,1,1));
    bSearch.addListener(SWT.Selection,new Listener(){
      public void handleEvent(      Event event){
        pageToolBar.reset();
        doSearch();
      }
    }
);
    Composite compSecondLine=toolkit.createComposite(composite,SWT.NONE);
    compSecondLine.setLayoutData(new GridData(SWT.FILL,SWT.NONE,true,false));
    compSecondLine.setLayout(new GridLayout(9,false));
    Label keyLabel=toolkit.createLabel(compSecondLine,"String_Node_Str",SWT.NULL);
    keyLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    keyText=toolkit.createText(compSecondLine,"String_Node_Str",SWT.BORDER | SWT.MULTI);
    keyText.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,true,false,3,1));
    keyText.addKeyListener(keylistener);
    Label descriptionLabel=toolkit.createLabel(compSecondLine,"String_Node_Str",SWT.NULL);
    descriptionLabel.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    searchText=toolkit.createText(compSecondLine,"String_Node_Str",SWT.BORDER | SWT.MULTI);
    searchText.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,true,false,3,1));
    searchText.addKeyListener(keylistener);
    checkFTSearchButton=toolkit.createButton(compSecondLine,"String_Node_Str",SWT.CHECK);
    checkFTSearchButton.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    Label fill=toolkit.createLabel(compSecondLine,"String_Node_Str",SWT.NULL);
    fill.setLayoutData(new GridData(SWT.RIGHT,SWT.CENTER,false,false,8,1));
    showTaskIdCB=toolkit.createButton(compSecondLine,"String_Node_Str",SWT.CHECK);
    showTaskIdCB.setLayoutData(new GridData(SWT.FILL,SWT.CENTER,false,false,1,1));
    pageToolBar=new PageingToolBar(composite);
    pageToolBar.getComposite().setLayoutData(new GridData(SWT.FILL,SWT.TOP,true,false,9,1));
    pageToolBar.getComposite().setVisible(false);
    pageToolBar.setPageingListener(this);
    int style=SWT.MULTI | SWT.BORDER | SWT.H_SCROLL| SWT.FULL_SELECTION| SWT.HIDE_SELECTION;
    resultsViewer=new TableViewer(composite,style);
    initTable(resultsViewer.getTable());
    resultsViewer.getControl().setLayoutData(new GridData(SWT.FILL,SWT.FILL,true,true,1,1));
    resultsViewer.setContentProvider(new ArrayContentProvider());
    resultsViewer.setLabelProvider(new ClusterTableLabelProvider());
    resultsViewer.addDoubleClickListener(new IDoubleClickListener(){
      public void doubleClick(      DoubleClickEvent event){
        resultsViewer.setSelection(event.getSelection());
        try {
          new EditItemAction(DataClusterBrowserMainPage.this.getSite().getShell(),resultsViewer).run();
        }
 catch (        Exception e) {
          MessageDialog.openError(DataClusterBrowserMainPage.this.getSite().getShell(),"String_Node_Str","String_Node_Str" + e.getClass().getName() + "String_Node_Str"+ e.getLocalizedMessage());
        }
      }
    }
);
    hookKeyboard();
    hookContextMenu();
    managedForm.reflow(true);
    searchText.setFocus();
    toolkit.adapt(composite);
  }
 catch (  Exception e) {
    log.error(e.getMessage(),e);
  }
}