コード例 #1
0
  @Override
  protected void createTabSection(CTabItem tabItem) {
    // Lazily create the other tabs
    switch (getFolder().indexOf(tabItem)) {
      case TAB_ENVIRONMENTS:
        if (fEnvironmentsSection == null) {
          fEnvironmentsSection = new ActivityEnvironmentsSection(getFolder());
          fEnvironmentsSection.createControls();
          tabItem.setControl(fEnvironmentsSection);
          fEnvironmentsSection.setInput(getInspectorProvider(), getElement());
        }
        break;

      case TAB_INFORMATION:
        if (fInformationSection == null) {
          fInformationSection = new ActivityStructureInformationSection(getFolder());
          fInformationSection.createControls();
          tabItem.setControl(fInformationSection);
          fInformationSection.setInput(getInspectorProvider(), getElement());
        }
        break;

      default:
        break;
    }
  }
コード例 #2
0
  @Override
  public void setInput(IInspectorProvider provider, Object element) {
    super.setInput(provider, element);

    if (fSettingsSection != null) {
      fSettingsSection.setInput(provider, element);
    }

    if (fEnvironmentsSection != null) {
      fEnvironmentsSection.setInput(provider, element);
    }

    if (fInformationSection != null) {
      fInformationSection.setInput(provider, element);
    }
  }