Example usage for com.intellij.openapi.ui DetailsComponent getComponent

List of usage examples for com.intellij.openapi.ui DetailsComponent getComponent

Introduction

In this page you can find the example usage for com.intellij.openapi.ui DetailsComponent getComponent.

Prototype

public JComponent getComponent() 

Source Link

Usage

From source file:com.android.tools.idea.gradle.variant.profiles.ProjectProfileSelectionDialog.java

License:Apache License

@NotNull
private JComponent createProjectStructurePanel() {
    createProjectStructureTree();/*from   w ww.  j  a va  2  s. c om*/

    DetailsComponent details = new DetailsComponent();
    details.setText("Project Structure");
    details.setContent(createTreePanel(myProjectStructureTree));

    removeEmptyBorder(details);
    return details.getComponent();
}

From source file:com.android.tools.idea.gradle.variant.profiles.ProjectProfileSelectionDialog.java

License:Apache License

@NotNull
private JComponent createConflictsPanel() {
    createConflictTree();/*from  w w  w  . j av a 2  s  .c  o  m*/

    myConflictDetails = new DetailsComponent();
    myConflictDetails.setText("Conflict Detail");
    myConflictDetails.setContent(createTreePanel(myConflictTree));
    removeEmptyBorder(myConflictDetails);

    createConflictsTable();

    myConflictsTable.getSelectionModel().addListSelectionListener(new ListSelectionListener() {
        @Override
        public void valueChanged(ListSelectionEvent e) {
            if (e.getValueIsAdjusting()) {
                return;
            }
            showConflictDetail();
        }
    });
    Splitter splitter = new Splitter(true, .25f);
    splitter.setHonorComponentsMinimumSize(true);

    DetailsComponent details = new DetailsComponent();
    details.setText("Variant Selection Conflicts");
    details.setContent(ScrollPaneFactory.createScrollPane(myConflictsTable));
    removeEmptyBorder(details);
    splitter.setFirstComponent(details.getComponent());

    splitter.setSecondComponent(myConflictDetails.getComponent());

    return splitter;
}