final String string = tableItem.getText(index);
horizontalAlignment = SWT.LEFT;
minimumWidth = Math.max(50, tableItem.getBounds(index).width);
final Text text = new Text(table, SWT.NONE);
setEditor(text, tableItem, index);
text.setFocus();
text.setText(string);
text.setSelection(0, string.length());
final String string = tableItem.getText(column);
horizontalAlignment = SWT.LEFT;
minimumWidth = Math.max(50, tableItem.getBounds(column).width);
final Text text = new Text(table, SWT.NONE);
setEditor(text, tableItem, column);
text.setFocus();
text.setText(string);
text.setSelection(0, string.length());
Clone fragments detected by clone detection tool
File path: /emf-2.4.1/src/org/eclipse/emf/converter/ui/contribution/base/ModelConverterPackagePage.java
|
|
File path: /emf-2.4.1/src/org/eclipse/emf/importer/rose/ui/RoseDetailPage.java
|
Method name: void editItem(TableItem, int)
|
|
Method name: void editItem(TableItem, int)
|
Number of AST nodes: 8
|
|
Number of AST nodes: 8
|
|
1 | final String string = tableItem.getText(index);↵ | | 1 | final String string = tableItem.getText(column);↵
|
2 | horizontalAlignment = SWT.LEFT;↵ | | 2 | horizontalAlignment = SWT.LEFT;↵
|
3 | minimumWidth = Math.max(50, tableItem.getBounds(index).width);↵ | | 3 | minimumWidth = Math.max(50, tableItem.getBounds(column).width);↵
|
|
| | | 4 | ↵
|
4 | final Text text = new Text(table, SWT.NONE);↵ | | 5 | final Text text = new Text(table, SWT.NONE);↵
|
5 | setEditor(text, tableItem, index);↵ | | 6 | setEditor(text, tableItem, column);↵
|
6 | text.setFocus();↵ | | 7 | text.setFocus();↵
|
7 | text.setText(string);↵ | | 8 | text.setText(string);↵
|
8 | text.setSelection(0, string.length()); | | 9 | text.setSelection(0, string.length());
|
See real code fragment |
|
See real code fragment |
Summary
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 | 0 |
-
{Non-refactorable}
Mapping Summary
Number of mapped statements | 0 |
Number of unmapped statements in the first code fragment | 0 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 0.0 |
Clone type | Unknown type |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
Precondition Violations (0)
Row |
Violation |