File path: /jEdit-4.2/src/org/gjt/sp/jedit/options/ToolBarOptionPane.java | File path: /jEdit-4.2/src/org/gjt/sp/jedit/options/ContextOptionPane.java | |||
Method name: void ToolBarEditDialog(Component, DefaultComboBoxModel, ToolBarOptionPane.Button)
|
Method name: void ContextAddDialog(Component)
|
|||
Number of AST nodes: 16 | Number of AST nodes: 16 | |||
1 | super(GUIUtilities.getParentDialog(comp),↵ | 1 | super(GUIUtilities.getParentDialog(comp),↵ | |
2 | jEdit.getProperty("options.toolbar.edit.title"),↵ | 2 | jEdit.getProperty("options.context.add.title"),↵ | |
3 | true);↵ | 3 | true);↵ | |
4 | JPanel content = new JPanel(new BorderLayout());↵ | 4 | JPanel content = new JPanel(new BorderLayout());↵ | |
5 | content.setBorder(new EmptyBorder(12,12,12,12));↵ | 5 | content.setBorder(new EmptyBorder(12,12,12,12));↵ | |
6 | setContentPane(content);↵ | 6 | setContentPane(content);↵ | |
7 | ActionHandler actionHandler = new ActionHandler();↵ | 7 | ActionHandler actionHandler = new ActionHandler();↵ | |
8 | ButtonGroup grp = new ButtonGroup();↵ | 8 | ButtonGroup grp = new ButtonGroup();↵ | |
9 | JPanel typePanel = new JPanel(new GridLayout(3,1,6,6));↵ | 9 | JPanel typePanel = new JPanel(new GridLayout(3,1,6,6));↵ | |
10 | typePanel.setBorder(new EmptyBorder(0,0,6,0));↵ | 10 | typePanel.setBorder(new EmptyBorder(0,0,6,0));↵ | |
11 | typePanel.add(new JLabel(↵ | 11 | typePanel.add(new JLabel(↵ | |
12 | jEdit.getProperty("options.toolbar.edit.caption")));↵ | 12 | jEdit.getProperty("options.context.add.caption")));↵ | |
13 | separator = new JRadioButton(jEdit.getProperty("options.toolbar"↵ | 13 | separator = new JRadioButton(jEdit.getProperty("options.context"↵ | |
14 | + ".edit.separator"));↵ | 14 | + ".add.separator"));↵ | |
15 | separator.addActionListener(actionHandler);↵ | 15 | separator.addActionListener(actionHandler);↵ | |
16 | grp.add(separator);↵ | 16 | grp.add(separator);↵ | |
17 | typePanel.add(separator);↵ | 17 | typePanel.add(separator);↵ | |
18 | action = new JRadioButton(jEdit.getProperty("options.toolbar"↵ | 18 | action = new JRadioButton(jEdit.getProperty("options.context"↵ | |
19 | + ".edit.action"));↵ | 19 | + ".add.action"));↵ | |
20 | action.addActionListener(actionHandler);↵ | 20 | action.addActionListener(actionHandler);↵ | |
21 | grp.add(action); | 21 |
| |
See real code fragment | See real code fragment |
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 1 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | Clones are in different classes having the same super class |
Number of node comparisons | 108 |
Number of mapped statements | 15 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 1 |
Time elapsed for statement mapping (ms) | 0.0 |
Clone type | Type 2 |
ID | Statement | ID | Statement | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
1 | super(GUIUtilities.getParentDialog(comp), jEdit.getProperty("options.toolbar.edit.title"), true); |
| 1 | super(GUIUtilities.getParentDialog(comp), jEdit.getProperty("options.context.add.title"), true); | |||||||||||||
2 | JPanel content = new JPanel(new BorderLayout()); | 2 | JPanel content = new JPanel(new BorderLayout()); | ||||||||||||||
3 | content.setBorder(new EmptyBorder(12, 12, 12, 12)); | 3 | content.setBorder(new EmptyBorder(12, 12, 12, 12)); | ||||||||||||||
4 | setContentPane(content); | 4 | setContentPane(content); | ||||||||||||||
| 5 | ActionHandler actionHandler = new ActionHandler(); | |||||||||||||||
5 | ActionHandler actionHandler = new ActionHandler(); | | |||||||||||||||
6 | ButtonGroup grp = new ButtonGroup(); | 6 | ButtonGroup grp = new ButtonGroup(); | ||||||||||||||
7 | JPanel typePanel = new JPanel(new GridLayout(3, 1, 6, 6)); | 7 | JPanel typePanel = new JPanel(new GridLayout(3, 1, 6, 6)); | ||||||||||||||
8 | typePanel.setBorder(new EmptyBorder(0, 0, 6, 0)); | 8 | typePanel.setBorder(new EmptyBorder(0, 0, 6, 0)); | ||||||||||||||
9 | typePanel.add(new JLabel(jEdit.getProperty("options.toolbar.edit.caption"))); |
| 9 | typePanel.add(new JLabel(jEdit.getProperty("options.context.add.caption"))); | |||||||||||||
10 | separator = new JRadioButton(jEdit.getProperty("options.toolbar" + ".edit.separator")); |
| 10 | separator = new JRadioButton(jEdit.getProperty("options.context" + ".add.separator")); | |||||||||||||
11 | separator.addActionListener(actionHandler); |
| 11 | separator.addActionListener(actionHandler); | |||||||||||||
12 | grp.add(separator); | 12 | grp.add(separator); | ||||||||||||||
13 | typePanel.add(separator); | 13 | typePanel.add(separator); | ||||||||||||||
14 | action = new JRadioButton(jEdit.getProperty("options.toolbar" + ".edit.action")); |
| 14 | action = new JRadioButton(jEdit.getProperty("options.context" + ".add.action")); | |||||||||||||
15 | action.addActionListener(actionHandler); |
| 15 | action.addActionListener(actionHandler); | |||||||||||||
16 | grp.add(action); | 16 | grp.add(action); |
Row | Violation |
---|---|
1 | Type org.gjt.sp.jedit.options.ToolBarEditDialog.ActionHandler of variable actionHandler does not match with type org.gjt.sp.jedit.options.ContextAddDialog.ActionHandler of variable actionHandler |
2 | Type org.gjt.sp.jedit.options.ToolBarEditDialog.ActionHandler of variable actionHandler does not match with type org.gjt.sp.jedit.options.ContextAddDialog.ActionHandler of variable actionHandler |
3 | Clone fragment #1 returns variables typePanel, content, grp , while Clone fragment #2 returns variables typePanel, content |