public void localeChanged(LocaleChangeEvent event) { // FIrst make sure we save the content of the current GUI (since we // will flush it away): updateCurrentNode(); // Forget about all GUIs we've created so far: we'll need to re-created // them all! guis = new HashMap(); nodesToGui = new HashMap(); testBeanGUIs = new HashMap(); // BeanInfo objects also contain locale-sensitive data -- flush them // away: Introspector.flushCaches(); // Now put the current GUI in place. [This code was copied from the // EditCommand action -- we can't just trigger the action because that // would populate the current node with the contents of the new GUI -- // which is empty.] MainFrame mf = getMainFrame(); // Fetch once if (mf == null) // Probably caused by unit testing on headless system { log.warn("Mainframe is null"); } else { mf.setMainPanel((javax.swing.JComponent) getCurrentGui()); mf.setEditMenu(getTreeListener().getCurrentNode().createPopupMenu());
public void localeChanged(LocaleChangeEvent event) { // FIrst make sure we save the content of the current GUI (since we // will flush it away): updateCurrentNode(); // Forget about all GUIs we've created so far: we'll need to re-created // them all! guis = new HashMap(); nodesToGui = new HashMap(); testBeanGUIs = new HashMap(); // BeanInfo objects also contain locale-sensitive data -- flush them // away: Introspector.flushCaches(); // Now put the current GUI in place. [This code was copied from the // EditCommand action -- we can't just trigger the action because that // would populate the current node with the contents of the new GUI -- // which is empty.] ReportMainFrame mf = getMainFrame(); // Fetch once if (mf == null) // Probably caused by unit testing on headless system { log.warn("Mainframe is null"); } else { mf.setMainPanel((javax.swing.JComponent) getCurrentGui()); mf.setEditMenu(getTreeListener().getCurrentNode().createPopupMenu());
Clone fragments detected by clone detection tool
File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/gui/GuiPackage.java File path: /jakarta-jmeter-2.3.2/src/org/apache/jmeter/gui/ReportGuiPackage.java
Method name: Method name:
Number of AST nodes: 0 Number of AST nodes: 0
1
public void localeChanged(LocaleChangeEvent event) {
1
public void localeChanged(LocaleChangeEvent event) {
2
		// FIrst make sure we save the content of the current GUI (since we
2
		// FIrst make sure we save the content of the current GUI (since we
3
		// will flush it away):
3
		// will flush it away):
4
		updateCurrentNode();
4
		updateCurrentNode();
5
		// Forget about all GUIs we've created so far: we'll need to re-created
5
		// Forget about all GUIs we've created so far: we'll need to re-created
6
		// them all!
6
		// them all!
7
		guis = new HashMap();
7
		guis = new HashMap();
8
		nodesToGui = new HashMap();
8
		nodesToGui = new HashMap();
9
		testBeanGUIs = new HashMap();
9
		testBeanGUIs = new HashMap();
10
		// BeanInfo objects also contain locale-sensitive data -- flush them
10
		// BeanInfo objects also contain locale-sensitive data -- flush them
11
		// away:
11
		// away:
12
		Introspector.flushCaches();
12
		Introspector.flushCaches();
13
		// Now put the current GUI in place. [This code was copied from the
13
		// Now put the current GUI in place. [This code was copied from the
14
		// EditCommand action -- we can't just trigger the action because that
14
		// EditCommand action -- we can't just trigger the action because that
15
		// would populate the current node with the contents of the new GUI --
15
		// would populate the current node with the contents of the new GUI --
16
		// which is empty.]
16
		// which is empty.]
17
		MainFrame mf = getMainFrame(); // Fetch once
17
		ReportMainFrame mf = getMainFrame(); // Fetch once
18
		if (mf == null) // Probably caused by unit testing on headless system
18
		if (mf == null) // Probably caused by unit testing on headless system
19
		{
19
		{
20
			log.warn("Mainframe is null");
20
			log.warn("Mainframe is null");
21
		} else {
21
		} else {
22
			mf.setMainPanel((javax.swing.JComponent) getCurrentGui());
22
			mf.setMainPanel((javax.swing.JComponent) getCurrentGui());
23
			mf.setEditMenu(getTreeListener().getCurrentNode().createPopupMenu());
23
			mf.setEditMenu(getTreeListener().getCurrentNode().createPopupMenu());
24
		
24
		
Summary
Number of common nesting structure subtrees0
Number of refactorable cases0
Number of non-refactorable cases0
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones location
Number of node comparisons0