Bug 76416 Method signature using QuickFix incorrect in static methods
Very Minor bug, When using quickfix to create method in an static anonymous inner class.. then the resulting method created is not static... but it needs to be. Example: 1. Create Class: public class SwingApplication { public static void main(String[] args) { SwingUtilities.invokeLater(new Runnable(){ public void run() { createGui(); } } ); } } 2. Eclipse will give error that createGui() does not exist. 3. Use quickfix, and select 'Create method 'createGui()' in SwingApplication'. 4. Notice that the created method should be static...
org.eclipse.jdt.ui.tests/ui/org/eclipse/jdt/ui/tests/quickfix/UnresolvedMethodsQuickFixTest.java
buf.append("public class E {\n");
		buf.append("    public void foo() {\n");
		buf.append("        X.xoo(1, null);\n");
		buf.append("    }\n");
		buf.append("}\n");
		String expected1= buf.toString();
		
		proposal= (CUCorrectionProposal) proposals.get(1);
		String preview2= getPreviewContent(proposal);
		buf= new StringBuffer();
		buf.append("package test1;\n");
		buf.append("public class X {\n");
		buf.append("    /**\n");
		buf.append("     * @param i The int value\n");
		buf.append("     *                  More about the int value\n");
		buf.append("     * @param o The Object value\n");
		buf.append("     */\n");
		buf.append("    public static void xoo(int i, Object o) {\n");
		buf.append("    }\n");
		buf.append("\n");
		buf.append("    public static void xoo(int i) {\n");
		buf.append("    }\n");		
		buf.append("}\n");
		String expected2= buf.toString();
		proposal= (CUCorrectionProposal) proposals.get(2);
		String preview3= getPreviewContent(proposal);
		buf= new StringBuffer();
		buf.append("package test1;\n");
		buf.append("public class X {\n");
		buf.append("    /**\n");