1 | void init() {↵ | | 1 | void init() {↵
|
2 | setLayout(new BorderLayout(0, 5));↵ | | 2 | setLayout(new BorderLayout(0, 5));↵
|
3 | setBorder(makeBorder());↵ | | 3 | setBorder(makeBorder());↵
|
|
4 | Box box = Box.createVerticalBox();↵ | | 4 | Box box = Box.createVerticalBox();↵
|
5 | box.add(makeTitlePanel());↵ | | 5 | box.add(makeTitlePanel());↵
|
6 | box.add(createResetPanel());↵ | | 6 | box.add(createResetPanel());↵
|
7 | box.add(createParameterPanel());↵ | | 7 | box.add(createParameterPanel());↵
|
8 | box.add(createFilenamePanel());↵ | | 8 | box.add(createFilenamePanel());↵
|
9 | add(box, BorderLayout.NORTH);↵ | | 9 | add(box, BorderLayout.NORTH);↵
|
|
10 | JPanel panel = createScriptPanel();↵ | | 10 | JPanel panel = createScriptPanel();↵
|
11 | add(panel, BorderLayout.CENTER);↵ | | 11 | add(panel, BorderLayout.CENTER);↵
|
12 | // Don't let the input field shrink too much↵ | | 12 | // Don't let the input field shrink too much↵
|
13 | add(Box.createVerticalStrut(panel.getPreferredSize().height), BorderLayout.WEST);↵ | | 13 | add(Box.createVerticalStrut(panel.getPreferredSize().height), BorderLayout.WEST);↵
|
14 | }↵ | | 14 | }↵
|
|
15 | private JPanel createScriptPanel() {↵ | | 15 | private JPanel createScriptPanel() {↵
|
16 | scriptField = new JTextArea();↵ | | 16 | scriptField = new JTextArea();↵
|
17 | scriptField.setRows(4);↵ | | 17 | scriptField.setRows(4);↵
|
18 | scriptField.setLineWrap(true);↵ | | 18 | scriptField.setLineWrap(true);↵
|
19 | scriptField.setWrapStyleWord(true);↵ | | 19 | scriptField.setWrapStyleWord(true);↵
|
|
20 | JLabel label = new JLabel(JMeterUtils.getResString("bsh_assertion_script")); //$NON-NLS-1$↵ | | 20 | JLabel label = new JLabel(JMeterUtils.getResString("bsh_script")); // $NON-NLS-1$↵
|
21 | label.setLabelFor(scriptField);↵ | | 21 | label.setLabelFor(scriptField);↵
|
|
22 | JPanel panel = new JPanel(new BorderLayout());↵ | | 22 | JPanel panel = new JPanel(new BorderLayout());↵
|
23 | panel.add(label, BorderLayout.NORTH);↵ | | 23 | panel.add(label, BorderLayout.NORTH);↵
|
24 | panel.add(new JScrollPane(scriptField), BorderLayout.CENTER);↵ | | 24 | panel.add(new JScrollPane(scriptField), BorderLayout.CENTER);↵
|
| | | 25 | ↵
|
25 | JTextArea explain = new JTextArea(JMeterUtils.getResString("bsh_assertion_script_variables")); //$NON-NLS-1$↵ | | 26 | JTextArea explain = new JTextArea(JMeterUtils.getResString("bsh_script_variables")); //$NON-NLS-1$↵
|
26 | explain.setLineWrap(true);↵ | | 27 | explain.setLineWrap(true);↵
|
27 | explain.setEditable(false);↵ | | 28 | explain.setEditable(false);↵
|
28 | explain.setBackground(this.getBackground());↵ | | 29 | explain.setBackground(this.getBackground());↵
|
29 | panel.add(explain, BorderLayout.SOUTH);↵ | | 30 | panel.add(explain, BorderLayout.SOUTH);↵
|
|
30 | return panel;↵ | | 31 | return panel;↵
|
31 | } | | 32 | }
|