in profiler/profiler.snaptracer/src/org/netbeans/modules/profiler/snaptracer/impl/options/TracerOptionsPanel.java [575:1330]
private void initComponents() {
setLayout(new GridBagLayout());
GridBagConstraints c;
// probesDefaultsSeparator
SectionSeparator probesDefaultsSeparator =
new SectionSeparator("Probes Settings"); // NOI18N
c = new GridBagConstraints();
c.gridy = 0;
c.gridwidth = GridBagConstraints.REMAINDER;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.HORIZONTAL;
c.insets = new Insets(0, 0, 5, 0);
add(probesDefaultsSeparator, c);
JLabel probesDefaultsLabel = new JLabel("Initial appearance:");
c.gridx = 0;
c.gridy = 1;
c.gridwidth = 1;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.NONE;
c.insets = new Insets(3, 15, 3, 5);
add(probesDefaultsLabel, c);
// probesDefaultsCombo
probesDefaultsCombo = new JComboBox(new String[] { "first expanded",
"all expanded",
"all collapsed" }) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
protected void selectedItemChanged() {
TracerOptionsPanel.this.update();
super.selectedItemChanged();
}
};
probesDefaultsLabel.setLabelFor(probesDefaultsCombo);
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 1;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(probesDefaultsCombo, c);
// timelineDefaultsSeparator
SectionSeparator timelineDefaultsSeparator =
new SectionSeparator("Timeline Settings"); // NOI18N
c = new GridBagConstraints();
c.gridy = 2;
c.gridwidth = GridBagConstraints.REMAINDER;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.HORIZONTAL;
c.insets = new Insets(15, 0, 5, 0);
add(timelineDefaultsSeparator, c);
JLabel refreshRateLabel = new JLabel("Sampling frequency:");
c.gridx = 0;
c.gridy = 3;
c.gridwidth = 1;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.NONE;
c.insets = new Insets(3, 15, 3, 5);
add(refreshRateLabel, c);
Integer[] refreshRates = new Integer[] { -1, 100, 200, 500, 1000, 2000, 5000, 10000 };
refreshCombo = new JComboBox(refreshRates) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
protected void selectedItemChanged() {
TracerOptionsPanel.this.update();
super.selectedItemChanged();
}
};
refreshRateLabel.setLabelFor(refreshCombo);
refreshCombo.setRenderer(new CustomComboRenderer.Number(refreshCombo, "ms", true));
refreshCombo.setEditable(false);
c.gridx = 1;
c.gridy = 3;
c.gridwidth = 1;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.HORIZONTAL;
c.insets = new Insets(3, 5, 3, 0);
add(refreshCombo, c);
refreshCheckBox = new JCheckBox("Customizable in Tracer tab") {
public Dimension getPreferredSize() {
Dimension d = super.getPreferredSize();
d.height = Math.min(d.height, refreshCombo.getPreferredSize().height);
return d;
}
public Dimension getMinimumSize() {
return getPreferredSize();
}
};
c.gridx = 2;
c.gridy = 3;
c.gridwidth = 1;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.NONE;
c.insets = new Insets(3, 5, 3, 0);
add(refreshCheckBox, c);
// zoomModeLabel
JLabel zoomModeLabel = new JLabel("Zoom mode:");
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 4;
c.gridwidth = 1;
c.fill = GridBagConstraints.NONE;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 15, 3, 5);
add(zoomModeLabel, c);
// zoomModeCombo
zoomModeCombo = new JComboBox(new String[] {
TracerOptions.FIXED_SCALE,
TracerOptions.SCALE_TO_FIT }) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
protected void selectedItemChanged() {
TracerOptionsPanel.this.update();
super.selectedItemChanged();
}
};
zoomModeLabel.setLabelFor(zoomModeCombo);
zoomModeCombo.setRenderer(new CustomComboRenderer.String(zoomModeCombo));
zoomModeCombo.setEditable(false);
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 4;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(zoomModeCombo, c);
// customizableZoomModeLabel
JLabel customizableZoomModeLabel = new JLabel("Customizable in Tracer tab");
customizableZoomModeLabel.setEnabled(false);
c.gridx = 2;
c.gridy = 4;
c.gridwidth = 1;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.NONE;
c.insets = new Insets(3, 9, 3, 0);
add(customizableZoomModeLabel, c);
// mouseWheelLabel
JLabel mouseWheelLabel = new JLabel("Mouse wheel action:");
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 5;
c.gridwidth = 1;
c.fill = GridBagConstraints.NONE;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 15, 3, 5);
add(mouseWheelLabel, c);
// mouseWheelCombo
mouseWheelCombo = new JComboBox(new String[] {
TracerOptions.MOUSE_WHEEL_ZOOMS,
TracerOptions.MOUSE_WHEEL_HSCROLLS,
TracerOptions.MOUSE_WHEEL_VSCROLLS }) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
protected void selectedItemChanged() {
TracerOptionsPanel.this.update();
super.selectedItemChanged();
}
};
mouseWheelLabel.setLabelFor(mouseWheelCombo);
mouseWheelCombo.setRenderer(new CustomComboRenderer.String(mouseWheelCombo));
mouseWheelCombo.setEditable(false);
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 5;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(mouseWheelCombo, c);
// customizableMouseWheelLabel
JLabel customizableMouseWheelLabel = new JLabel("Customizable in Tracer tab");
customizableMouseWheelLabel.setEnabled(false);
c.gridx = 2;
c.gridy = 5;
c.gridwidth = 1;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.NONE;
c.insets = new Insets(3, 9, 3, 0);
add(customizableMouseWheelLabel, c);
// timelineAppearanceSeparator
SectionSeparator timelineAppearanceSeparator =
new SectionSeparator("Timeline Appearance"); // NOI18N
c = new GridBagConstraints();
c.gridy = 6;
c.gridwidth = GridBagConstraints.REMAINDER;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.HORIZONTAL;
c.insets = new Insets(15, 0, 5, 0);
add(timelineAppearanceSeparator, c);
// minMaxValsLabel
JLabel minMaxValsLabel = new JLabel("Show min/max values:");
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 7;
c.gridwidth = 1;
c.fill = GridBagConstraints.NONE;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 15, 3, 5);
add(minMaxValsLabel, c);
// minMaxValsCombo
minMaxValsCombo = new JComboBox(new Boolean[] { Boolean.TRUE,
Boolean.FALSE }) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
};
minMaxValsLabel.setLabelFor(minMaxValsCombo);
minMaxValsCombo.setRenderer(new CustomComboRenderer.Boolean(minMaxValsCombo));
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 7;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(minMaxValsCombo, c);
// customizableMinMaxValsLabel
JLabel customizableMinMaxValsLabel = new JLabel("Customizable in Tracer tab");
customizableMinMaxValsLabel.setEnabled(false);
c.gridx = 2;
c.gridy = 7;
c.gridwidth = 1;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.NONE;
c.insets = new Insets(3, 9, 3, 0);
add(customizableMinMaxValsLabel, c);
// rowLegendLabel
JLabel rowLegendLabel = new JLabel("Show row legend:");
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 8;
c.gridwidth = 1;
c.fill = GridBagConstraints.NONE;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 15, 3, 5);
add(rowLegendLabel, c);
// rowLegendCombo
rowLegendCombo = new JComboBox(new Boolean[] { Boolean.TRUE,
Boolean.FALSE }) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
};
rowLegendLabel.setLabelFor(rowLegendCombo);
rowLegendCombo.setRenderer(new CustomComboRenderer.Boolean(rowLegendCombo));
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 8;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(rowLegendCombo, c);
// customizableRowLegendLabel
JLabel customizableRowLegendLabel = new JLabel("Customizable in Tracer tab");
customizableRowLegendLabel.setEnabled(false);
c.gridx = 2;
c.gridy = 8;
c.gridwidth = 1;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.NONE;
c.insets = new Insets(3, 9, 3, 0);
add(customizableRowLegendLabel, c);
// rowsDecorationLabel
JLabel rowsDecorationLabel = new JLabel("Rows decoration:");
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 9;
c.gridwidth = 1;
c.fill = GridBagConstraints.NONE;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 15, 3, 5);
add(rowsDecorationLabel, c);
// rowsDecorationCombo
rowsDecorationCombo = new JComboBox(new Boolean[] { Boolean.TRUE,
Boolean.FALSE }) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
};
rowsDecorationLabel.setLabelFor(rowsDecorationCombo);
rowsDecorationCombo.setRenderer(new CustomComboRenderer.Boolean(rowsDecorationCombo));
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 9;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(rowsDecorationCombo, c);
// rowsSelectionLabel
JLabel rowsSelectionLabel = new JLabel("Rows selection:");
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 10;
c.gridwidth = 1;
c.fill = GridBagConstraints.NONE;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 15, 3, 5);
add(rowsSelectionLabel, c);
// rowsSelectionCombo
rowsSelectionCombo = new JComboBox(new String[] { "panel and chart",
"panel only" }) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
};
rowsSelectionLabel.setLabelFor(rowsSelectionCombo);
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 10;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(rowsSelectionCombo, c);
// toolbarsBehaviorSeparator
SectionSeparator toolbarsBehaviorSeparator =
new SectionSeparator("Toolbars Behavior"); // NOI18N
c = new GridBagConstraints();
c.gridy = 11;
c.gridwidth = GridBagConstraints.REMAINDER;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.HORIZONTAL;
c.insets = new Insets(15, 0, 5, 0);
add(toolbarsBehaviorSeparator, c);
// minMaxValsLabel
JLabel timelineToolbarLabel = new JLabel("Timeline toolbar:");
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 12;
c.gridwidth = 1;
c.fill = GridBagConstraints.NONE;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 15, 3, 5);
add(timelineToolbarLabel, c);
// timelineToolbarCombo
timelineToolbarCombo = new JComboBox(new String[] { "always visible",
"show with timeline" }) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
protected void selectedItemChanged() {
TracerOptionsPanel.this.update();
super.selectedItemChanged();
}
};
timelineToolbarLabel.setLabelFor(timelineToolbarCombo);
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 12;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(timelineToolbarCombo, c);
// selectionToolbarLabel
JLabel selectionToolbarLabel = new JLabel("Selection toolbar:");
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 13;
c.gridwidth = 1;
c.fill = GridBagConstraints.NONE;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 15, 3, 5);
add(selectionToolbarLabel, c);
// rowLegendCombo
selectionToolbarCombo = new JComboBox(new String[] { "always visible",
"show on selection",
"always hidden"}) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
protected void selectedItemChanged() {
TracerOptionsPanel.this.update();
super.selectedItemChanged();
}
};
selectionToolbarLabel.setLabelFor(selectionToolbarCombo);
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 13;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(selectionToolbarCombo, c);
// extraToolbarLabel
JLabel extraToolbarLabel = new JLabel("Export toolbar:");
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 14;
c.gridwidth = 1;
c.fill = GridBagConstraints.NONE;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 15, 3, 5);
add(extraToolbarLabel, c);
// extraToolbarCombo
extraToolbarCombo = new JComboBox(new String[] { "always visible",
"show on data",
"always hidden"}) {
public Dimension getMinimumSize() {
return getPreferredSize();
}
protected void selectedItemChanged() {
TracerOptionsPanel.this.update();
super.selectedItemChanged();
}
};
extraToolbarLabel.setLabelFor(extraToolbarCombo);
c = new GridBagConstraints();
c.gridx = 1;
c.gridy = 14;
c.gridwidth = 1;
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.WEST;
c.insets = new Insets(3, 5, 3, 0);
add(extraToolbarCombo, c);
// viewsBehaviorSeparator
SectionSeparator viewsBehaviorSeparator =
new SectionSeparator("Views Behavior"); // NOI18N
c = new GridBagConstraints();
c.gridy = 15;
c.gridwidth = GridBagConstraints.REMAINDER;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.HORIZONTAL;
c.insets = new Insets(15, 0, 5, 0);
add(viewsBehaviorSeparator, c);
// viewsBehaviorPanel
JPanel viewsBehaviorPanel = new JPanel(new BorderLayout(0, 0));
viewsBehaviorPanel.setOpaque(false);
c = new GridBagConstraints();
c.gridy = 16;
c.gridwidth = GridBagConstraints.REMAINDER;
c.anchor = GridBagConstraints.NORTHWEST;
c.fill = GridBagConstraints.HORIZONTAL;
c.insets = new Insets(8, 15, 0, 0);
add(viewsBehaviorPanel, c);
final CardLayout viewsSettingsLayout = new CardLayout();
final JPanel viewsSettingsContainer = new JPanel(viewsSettingsLayout);
final String INITIALLY_OPEN = "Initial appearance";
final String OPEN_PROBE_ADDED = "Probe added or removed";
final String OPEN_SESSION_STARTS = "Session started";
final String OPEN_ROW_SELECTED = "Row selected or unselected";
final DefaultListModel connectionTypeListModel = new DefaultListModel();
connectionTypeListModel.addElement(INITIALLY_OPEN);
connectionTypeListModel.addElement(OPEN_PROBE_ADDED);
connectionTypeListModel.addElement(OPEN_SESSION_STARTS);
connectionTypeListModel.addElement(OPEN_ROW_SELECTED);
JList connectionTypeList = new JList(connectionTypeListModel);
connectionTypeList.setVisibleRowCount(connectionTypeListModel.getSize());
connectionTypeList.setSelectionModel(new DefaultListSelectionModel() {
public void setSelectionInterval(int index0, int index1) {
super.setSelectionInterval(index0, index1);
viewsSettingsLayout.show(viewsSettingsContainer, connectionTypeListModel.get(getMinSelectionIndex()).toString());
}
public void removeSelectionInterval(int i1, int i2) {}
});
connectionTypeList.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
connectionTypeList.setSelectedIndex(0);
final ListCellRenderer defaultRenderer = connectionTypeList.getCellRenderer();
Component rc = defaultRenderer.getListCellRendererComponent(connectionTypeList, "X", 0, false, false); // NOI18N
connectionTypeList.setFixedCellHeight(rc.getPreferredSize().height + 2);
connectionTypeList.setCellRenderer(new ListCellRenderer() {
public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected, boolean cellHasFocus) {
return defaultRenderer.getListCellRendererComponent(list, " " + value + " ", index, isSelected, cellHasFocus); // NOI18N
}
});
JScrollPane connectionTypeScroll = new JScrollPane(connectionTypeList,
JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED,
JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED) {
public Dimension getMinimumSize() { return getPreferredSize(); }
};
createBorder(connectionTypeScroll, BorderFactory.createEmptyBorder(0, 0, 0, 10));
viewsBehaviorPanel.add(connectionTypeScroll, BorderLayout.WEST);
viewsBehaviorPanel.add(viewsSettingsContainer, BorderLayout.CENTER);
// initiallyOpenedPanel
initiallyOpenedPanel = new JPanel(new VerticalLayout(false));
initiallyOpenedPanel.setBorder(titledBorder("Select the views to open:"));
initiallyOpenedPanel.setOpaque(false);
// initialProbesCheckBox
initialProbesCheckBox = new JCheckBox("Probes") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
initiallyOpenedPanel.add(initialProbesCheckBox);
// initialTimelineCheckBox
initialTimelineCheckBox = new JCheckBox("Timeline") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
initiallyOpenedPanel.add(initialTimelineCheckBox);
// initialDetailsCheckBox
initialDetailsCheckBox = new JCheckBox("Details") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
initiallyOpenedPanel.add(initialDetailsCheckBox);
viewsSettingsContainer.add(initiallyOpenedPanel, INITIALLY_OPEN);
// onProbeAddedPanel
onProbeAddedPanel = new JPanel(new VerticalLayout(false));
onProbeAddedPanel.setBorder(titledBorder("Open for selected probes:"));
onProbeAddedPanel.setOpaque(false);
// initialProbesCheckBox
onProbeAddedProbesCheckBox = new JCheckBox("Probes") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onProbeAddedPanel.add(onProbeAddedProbesCheckBox);
// initialTimelineCheckBox
onProbeAddedTimelineCheckBox = new JCheckBox("Timeline") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onProbeAddedPanel.add(onProbeAddedTimelineCheckBox);
// initialDetailsCheckBox
onProbeAddedDetailsCheckBox = new JCheckBox("Details") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onProbeAddedPanel.add(onProbeAddedDetailsCheckBox);
// onStartNothingCheckBox
onProbeAddedNothingCheckBox = new JCheckBox("No change") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onProbeAddedPanel.add(onProbeAddedNothingCheckBox);
// onProbeAddedPanel2
onProbeAddedPanel2 = new JPanel(new VerticalLayout(false));
onProbeAddedPanel2.setBorder(titledBorder("Open for no selection:"));
onProbeAddedPanel2.setOpaque(false);
// initialProbesCheckBox2
onProbeAddedProbesCheckBox2 = new JCheckBox("Probes") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onProbeAddedPanel2.add(onProbeAddedProbesCheckBox2);
// initialTimelineCheckBox2
onProbeAddedTimelineCheckBox2 = new JCheckBox("Timeline") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onProbeAddedPanel2.add(onProbeAddedTimelineCheckBox2);
// onProbeAddedDetailsCheckBox2
onProbeAddedDetailsCheckBox2 = new JCheckBox("Details") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onProbeAddedPanel2.add(onProbeAddedDetailsCheckBox2);
// onProbeAddedNothingCheckBox2
onProbeAddedNothingCheckBox2 = new JCheckBox("No change") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onProbeAddedPanel2.add(onProbeAddedNothingCheckBox2);
JPanel onProbeAddedContainer = new JPanel(new GridLayout(1, 2));
onProbeAddedContainer.add(onProbeAddedPanel);
onProbeAddedContainer.add(onProbeAddedPanel2);
viewsSettingsContainer.add(onProbeAddedContainer, OPEN_PROBE_ADDED);
// onStartOpenedPanel
onStartOpenedPanel = new JPanel(new VerticalLayout(false));
onStartOpenedPanel.setBorder(titledBorder("Select the views to open:"));
onStartOpenedPanel.setOpaque(false);
// initialProbesCheckBox
onStartProbesCheckBox = new JCheckBox("Probes") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onStartOpenedPanel.add(onStartProbesCheckBox);
// initialTimelineCheckBox
onStartTimelineCheckBox = new JCheckBox("Timeline") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onStartOpenedPanel.add(onStartTimelineCheckBox);
// initialDetailsCheckBox
onStartDetailsCheckBox = new JCheckBox("Details") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onStartOpenedPanel.add(onStartDetailsCheckBox);
// onStartNothingCheckBox
onStartNothingCheckBox = new JCheckBox("No change") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onStartOpenedPanel.add(onStartNothingCheckBox);
viewsSettingsContainer.add(onStartOpenedPanel, OPEN_SESSION_STARTS);
// onRowSelectedPanel
onRowSelectedPanel = new JPanel(new VerticalLayout(false));
onRowSelectedPanel.setBorder(titledBorder("Open for selected rows:"));
onRowSelectedPanel.setOpaque(false);
// initialProbesCheckBox
onRowSelectedProbesCheckBox = new JCheckBox("Probes") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onRowSelectedPanel.add(onRowSelectedProbesCheckBox);
// initialTimelineCheckBox
onRowSelectedTimelineCheckBox = new JCheckBox("Timeline") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onRowSelectedPanel.add(onRowSelectedTimelineCheckBox);
// initialDetailsCheckBox
onRowSelectedDetailsCheckBox = new JCheckBox("Details") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onRowSelectedPanel.add(onRowSelectedDetailsCheckBox);
// onStartNothingCheckBox
onRowSelectedNothingCheckBox = new JCheckBox("No change") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onRowSelectedPanel.add(onRowSelectedNothingCheckBox);
// onRowSelectedPanel2
onRowSelectedPanel2 = new JPanel(new VerticalLayout(false));
onRowSelectedPanel2.setBorder(titledBorder("Open for no selection:"));
onRowSelectedPanel2.setOpaque(false);
// initialProbesCheckBox2
onRowSelectedProbesCheckBox2 = new JCheckBox("Probes") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onRowSelectedPanel2.add(onRowSelectedProbesCheckBox2);
// initialTimelineCheckBox2
onRowSelectedTimelineCheckBox2 = new JCheckBox("Timeline") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onRowSelectedPanel2.add(onRowSelectedTimelineCheckBox2);
// onProbeAddedDetailsCheckBox2
onRowSelectedDetailsCheckBox2 = new JCheckBox("Details") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onRowSelectedPanel2.add(onRowSelectedDetailsCheckBox2);
// onProbeAddedNothingCheckBox2
onRowSelectedNothingCheckBox2 = new JCheckBox("No change") {
protected void fireActionPerformed(ActionEvent e) {
TracerOptionsPanel.this.update();
}
};
onRowSelectedPanel2.add(onRowSelectedNothingCheckBox2);
JPanel onRowSelectedContainer = new JPanel(new GridLayout(1, 2));
onRowSelectedContainer.add(onRowSelectedPanel);
onRowSelectedContainer.add(onRowSelectedPanel2);
viewsSettingsContainer.add(onRowSelectedContainer, OPEN_ROW_SELECTED);
// clearSelectionsCheckBox
clearSelectionsCheckBox = new JCheckBox("Clear selected rows when closing Details view") {
public Dimension getMinimumSize() {
return getPreferredSize();
}
};
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 17;
c.anchor = GridBagConstraints.WEST;
c.fill = GridBagConstraints.NONE;
c.gridwidth = GridBagConstraints.REMAINDER;
c.insets = new Insets(8, 15, 0, 0);
add(clearSelectionsCheckBox, c);
// bottomFiller
c = new GridBagConstraints();
c.gridx = 0;
c.gridy = 100;
c.weightx = 1;
c.weighty = 1;
c.anchor = GridBagConstraints.NORTHWEST;
c.fill = GridBagConstraints.BOTH;
c.gridwidth = GridBagConstraints.REMAINDER;
add(Spacer.create(), c);
}