if(prefixFocusOwner.isShowing())
{
prefixFocusOwner.requestFocus();
focusOnTextArea = true;
}
prefixFocusOwner = null;
if(prefixFocusOwner.isShowing())
{
prefixFocusOwner.requestFocus();
focusOnTextArea = true;
}
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/src/org/gjt/sp/jedit/View.java
|
|
File path: /jEdit-4.2/src/org/gjt/sp/jedit/View.java
|
Method name: void processKeyEvent(KeyEvent, int)
|
|
Method name: void processKeyEvent(KeyEvent, int)
|
Number of AST nodes: 4
|
|
Number of AST nodes: 3
|
|
1 | if(prefixFocusOwner.isShowing())↵ | | 1 | if(prefixFocusOwner.isShowing())↵
|
2 | {↵ | | 2 | {↵
|
3 | prefixFocusOwner.requestFocus();↵ | | 3 | prefixFocusOwner.requestFocus();↵
|
4 | focusOnTextArea = true;↵ | | 4 | focusOnTextArea = true;↵
|
5 | }↵ | | 5 | ↵
|
6 | prefixFocusOwner = null; | | 6 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 1 |
Number of refactorable cases | 1 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.2 |
Clones location | Clones are in the same method |
Number of node comparisons | 10 |
-
{Refactorable}
Mapping Summary
Number of mapped statements | 3 |
Number of unmapped statements in the first code fragment | 1 |
Number of unmapped statements in the second code fragment | 0 |
Time elapsed for statement mapping (ms) | 0.6 |
Clone type | Type 3 |
Mapped Statements
ID |
Statement |
|
ID |
Statement |
42 | if (prefixFocusOwner.isShowing()) | | 14 | if (prefixFocusOwner.isShowing()) |
43 | prefixFocusOwner.requestFocus(); | | 15 | prefixFocusOwner.requestFocus(); |
44 | | | 16 | |
45 | prefixFocusOwner = null; | | | |
Precondition Violations (0)
Row |
Violation |