switch (which) {
case 0:
row_height = Math.max(row_height, parent.getComponent(i).getMinimumSize().height);
break;
case 1:
row_height = Math.max(row_height, parent.getComponent(i).getMaximumSize().height);
break;
default:
row_height = Math.max(row_height, parent.getComponent(i).getPreferredSize().height);
break;
}
switch (which) {
case 0:
col_width = Math.max(col_width, parent.getComponent(i).getMinimumSize().width);
break;
case 1:
col_width = Math.max(col_width, parent.getComponent(i).getMaximumSize().width);
break;
default:
col_width = Math.max(col_width, parent.getComponent(i).getPreferredSize().width);
break;
}
Clone fragments detected by clone detection tool
File path: /jEdit-4.2/src/installer/VariableGridLayout.java
|
|
File path: /jEdit-4.2/src/org/gjt/sp/jedit/gui/VariableGridLayout.java
|
Method name:
|
|
Method name:
|
Number of AST nodes: 0
|
|
Number of AST nodes: 0
|
|
1 | switch (which) {↵ | | 1 | switch (which) {↵
|
2 | case 0:↵ | | 2 | case 0:↵
|
3 | row_height = Math.max(row_height, parent.getComponent(i).getMinimumSize().height);↵ | | 3 | col_width = Math.max(col_width, parent.getComponent(i).getMinimumSize().width);↵
|
4 | break;↵ | | 4 | break;↵
|
5 | case 1:↵ | | 5 | case 1:↵
|
6 | row_height = Math.max(row_height, parent.getComponent(i).getMaximumSize().height);↵ | | 6 | col_width = Math.max(col_width, parent.getComponent(i).getMaximumSize().width);↵
|
7 | break;↵ | | 7 | break;↵
|
8 | default:↵ | | 8 | default:↵
|
9 | row_height = Math.max(row_height, parent.getComponent(i).getPreferredSize().height);↵ | | 9 | col_width = Math.max(col_width, parent.getComponent(i).getPreferredSize().width);↵
|
10 | break;↵ | | 10 | break;↵
|
11 | } | | 11 | }
|
See real code fragment |
|
See real code fragment |
Summary
Number of common nesting structure subtrees | 0 |
Number of refactorable cases | 0 |
Number of non-refactorable cases | 0 |
Time elapsed for finding largest common nesting structure subtrees (ms) | 0.0 |
Clones location | |
Number of node comparisons | 0 |