コード例 #1
0
  /**
   * Creates the contents of this group in the normal dialog style
   *
   * @param parent parent composite
   */
  protected void createDialogContents(Composite parent) {
    fGrouping = GROUP_BY_NONE;

    Composite comp = SWTFactory.createComposite(parent, 2, 1, GridData.FILL_BOTH, 0, 0);

    createTree(comp, null);
    createButtons(comp, null);

    fCountLabel = SWTFactory.createLabel(comp, "", 2); // $NON-NLS-1$

    updateButtons();
    initializeFilters();
  }
コード例 #2
0
  /**
   * Creates the contents of this group, using the given toolkit where appropriate so that the
   * controls have the form editor look and feel.
   *
   * @param parent parent composite
   * @param toolkit toolkit to create controls with
   */
  protected void createFormContents(Composite parent, FormToolkit toolkit) {
    fGrouping = GROUP_BY_NONE;

    Composite comp = toolkit.createComposite(parent);
    GridLayout layout = new GridLayout(2, false);
    layout.marginWidth = layout.marginHeight = 0;
    comp.setLayout(layout);
    comp.setLayoutData(new GridData(GridData.FILL_BOTH));
    comp.setFont(parent.getFont());

    createTree(comp, toolkit);
    createButtons(comp, toolkit);

    fCountLabel = toolkit.createLabel(comp, ""); // $NON-NLS-1$
    GridData data = new GridData(GridData.FILL_HORIZONTAL);
    data.horizontalSpan = 2;
    fCountLabel.setLayoutData(data);

    updateButtons();
    initializeFilters();
  }