Search in sources :

Example 31 with HorizontalPanel

use of org.apache.jmeter.gui.util.HorizontalPanel in project jmeter by apache.

the class ServerPanel method init.

private void init() {
    // WARNING: called from ctor so must not be overridden (i.e. must be private or final)
    setLayout(new BorderLayout(5, 0));
    // Target server panel
    JPanel webServerPanel = new HorizontalPanel();
    webServerPanel.setBorder(BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), // $NON-NLS-1$
    JMeterUtils.getResString("target_server")));
    final JPanel domainPanel = getDomainPanel();
    final JPanel portPanel = getPortPanel();
    webServerPanel.add(domainPanel, BorderLayout.CENTER);
    webServerPanel.add(portPanel, BorderLayout.EAST);
    JPanel timeOut = new HorizontalPanel();
    timeOut.setBorder(BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), // $NON-NLS-1$
    JMeterUtils.getResString("web_server_timeout_title")));
    final JPanel connPanel = getConnectTimeOutPanel();
    final JPanel reqPanel = getResponseTimeOutPanel();
    timeOut.add(connPanel);
    timeOut.add(reqPanel);
    JPanel webServerTimeoutPanel = new VerticalPanel();
    webServerTimeoutPanel.add(webServerPanel, BorderLayout.CENTER);
    webServerTimeoutPanel.add(timeOut, BorderLayout.EAST);
    JPanel bigPanel = new VerticalPanel();
    bigPanel.add(webServerTimeoutPanel);
    add(bigPanel);
}
Also used : JPanel(javax.swing.JPanel) VerticalPanel(org.apache.jmeter.gui.util.VerticalPanel) BorderLayout(java.awt.BorderLayout) HorizontalPanel(org.apache.jmeter.gui.util.HorizontalPanel)

Example 32 with HorizontalPanel

use of org.apache.jmeter.gui.util.HorizontalPanel in project jmeter by apache.

the class ScopePanel method init.

/**
     * Initialize the GUI components and layout.
     */
private void init() {
    // WARNING: called from ctor so must not be overridden (i.e. must be private or final)
    setLayout(new BorderLayout(5, 0));
    //$NON-NLS-1$
    setBorder(BorderFactory.createTitledBorder(JMeterUtils.getResString("sample_scope")));
    parentButton.setSelected(true);
    JPanel buttonPanel = new HorizontalPanel();
    ButtonGroup group = new ButtonGroup();
    if (allButton != null) {
        group.add(allButton);
        buttonPanel.add(allButton);
    }
    group.add(parentButton);
    buttonPanel.add(parentButton);
    if (childButton != null) {
        group.add(childButton);
        buttonPanel.add(childButton);
    }
    if (variableButton != null) {
        variableButton.addActionListener(this);
        group.add(variableButton);
        buttonPanel.add(variableButton);
        buttonPanel.add(variableName);
    }
    add(buttonPanel);
}
Also used : JPanel(javax.swing.JPanel) BorderLayout(java.awt.BorderLayout) ButtonGroup(javax.swing.ButtonGroup) HorizontalPanel(org.apache.jmeter.gui.util.HorizontalPanel)

Example 33 with HorizontalPanel

use of org.apache.jmeter.gui.util.HorizontalPanel in project jmeter by apache.

the class JMSSubscriberGui method init.

/**
     * init() adds jndiICF to the mainPanel. The class reuses logic from
     * SOAPSampler, since it is common.
     */
private void init() {
    // WARNING: called from ctor so must not be overridden (i.e. must be private or final)
    setLayout(new BorderLayout());
    setBorder(makeBorder());
    add(makeTitlePanel(), BorderLayout.NORTH);
    JPanel mainPanel = new VerticalPanel();
    add(mainPanel, BorderLayout.CENTER);
    jndiICF.setToolTipText(Context.INITIAL_CONTEXT_FACTORY);
    urlField.setToolTipText(Context.PROVIDER_URL);
    jmsUser.setToolTipText(Context.SECURITY_PRINCIPAL);
    jmsPwd.setToolTipText(Context.SECURITY_CREDENTIALS);
    mainPanel.add(useProperties);
    mainPanel.add(jndiICF);
    mainPanel.add(urlField);
    mainPanel.add(jndiConnFac);
    mainPanel.add(createDestinationPane());
    mainPanel.add(jmsDurableSubscriptionId);
    mainPanel.add(jmsClientId);
    mainPanel.add(jmsSelector);
    mainPanel.add(useAuth);
    mainPanel.add(jmsUser);
    mainPanel.add(jmsPwd);
    mainPanel.add(samplesToAggregate);
    mainPanel.add(storeResponse);
    mainPanel.add(timeout);
    JPanel choice = new HorizontalPanel();
    choice.add(clientChoice);
    choice.add(stopBetweenSamples);
    mainPanel.add(choice);
    mainPanel.add(separator);
    mainPanel.add(jmsErrorReconnectOnCodes);
    mainPanel.add(jmsErrorPauseBetween);
    useProperties.addChangeListener(this);
    useAuth.addChangeListener(this);
}
Also used : JPanel(javax.swing.JPanel) VerticalPanel(org.apache.jmeter.gui.util.VerticalPanel) BorderLayout(java.awt.BorderLayout) HorizontalPanel(org.apache.jmeter.gui.util.HorizontalPanel)

Example 34 with HorizontalPanel

use of org.apache.jmeter.gui.util.HorizontalPanel in project jmeter by apache.

the class JMSPublisherGui method createPriorityAndExpiration.

/**
     * @return JPanel Panel for priority and expiration
     */
private JPanel createPriorityAndExpiration() {
    JPanel panel = new HorizontalPanel();
    panel.add(expiration);
    panel.add(priority);
    return panel;
}
Also used : JPanel(javax.swing.JPanel) HorizontalPanel(org.apache.jmeter.gui.util.HorizontalPanel)

Example 35 with HorizontalPanel

use of org.apache.jmeter.gui.util.HorizontalPanel in project jmeter by apache.

the class ProxyControlGui method createContentTypePanel.

private JPanel createContentTypePanel() {
    contentTypeInclude = new JTextField(35);
    contentTypeInclude.addKeyListener(this);
    contentTypeInclude.setName(ENABLE_RESTART);
    // $NON-NLS-1$
    JLabel labelInclude = new JLabel(JMeterUtils.getResString("proxy_content_type_include"));
    labelInclude.setLabelFor(contentTypeInclude);
    // Default value
    // $NON-NLS-1$
    contentTypeInclude.setText(JMeterUtils.getProperty("proxy.content_type_include"));
    contentTypeExclude = new JTextField(35);
    contentTypeExclude.addKeyListener(this);
    contentTypeExclude.setName(ENABLE_RESTART);
    // $NON-NLS-1$
    JLabel labelExclude = new JLabel(JMeterUtils.getResString("proxy_content_type_exclude"));
    labelExclude.setLabelFor(contentTypeExclude);
    // Default value
    // $NON-NLS-1$
    contentTypeExclude.setText(JMeterUtils.getProperty("proxy.content_type_exclude"));
    HorizontalPanel panel = new HorizontalPanel();
    panel.setBorder(BorderFactory.createTitledBorder(BorderFactory.createEtchedBorder(), // $NON-NLS-1$
    JMeterUtils.getResString("proxy_content_type_filter")));
    panel.add(labelInclude);
    panel.add(contentTypeInclude);
    panel.add(labelExclude);
    panel.add(contentTypeExclude);
    return panel;
}
Also used : HorizontalPanel(org.apache.jmeter.gui.util.HorizontalPanel) JLabel(javax.swing.JLabel) JTextField(javax.swing.JTextField)

Aggregations

HorizontalPanel (org.apache.jmeter.gui.util.HorizontalPanel)37 JPanel (javax.swing.JPanel)30 JLabel (javax.swing.JLabel)17 BorderLayout (java.awt.BorderLayout)15 JTextField (javax.swing.JTextField)15 VerticalPanel (org.apache.jmeter.gui.util.VerticalPanel)11 JCheckBox (javax.swing.JCheckBox)10 Dimension (java.awt.Dimension)6 JLabeledTextField (org.apache.jorphan.gui.JLabeledTextField)6 ButtonGroup (javax.swing.ButtonGroup)5 JRadioButton (javax.swing.JRadioButton)4 GridBagConstraints (java.awt.GridBagConstraints)3 GridBagLayout (java.awt.GridBagLayout)3 DefaultComboBoxModel (javax.swing.DefaultComboBoxModel)3 FlowLayout (java.awt.FlowLayout)2 JPasswordField (javax.swing.JPasswordField)2 JScrollPane (javax.swing.JScrollPane)2 JTabbedPane (javax.swing.JTabbedPane)2 Color (java.awt.Color)1 Format (java.text.Format)1