]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.utils.ui/testcases/org/simantics/utils/ui/SWTAWTTest.java
Fixed multiple issues causing dangling references to discarded queries
[simantics/platform.git] / bundles / org.simantics.utils.ui / testcases / org / simantics / utils / ui / SWTAWTTest.java
index fed7f7703865d14a9c48c082dc60206c1dd750b7..f963fe4c71e59e2b5d53a7bd93b62fa1d653cea1 100644 (file)
@@ -155,7 +155,7 @@ public class SWTAWTTest {
                                                                } catch (IllegalAccessException e) {
                                                                        e.printStackTrace();
                                                                } catch (InvocationTargetException e) {
-                                                                       e.printStackTrace();
+                                                                       e.getCause().printStackTrace();
                                                                }
                                                        }
                                                }
@@ -177,9 +177,9 @@ public class SWTAWTTest {
        private static JComponent createTable() {
                /* Creating components */
                int nrows = 1000, ncolumns = 10;
-               Vector<Object> rows = new Vector<Object>();
+               Vector<Vector<Object>> rows = new Vector<>();
                for (int i = 0; i < nrows; i++) {
-                       Vector<Object> row = new Vector<Object>();
+                       Vector<Object> row = new Vector<>();
                        for (int j = 0; j < ncolumns; j++) {
                                row.addElement("Item " + i + "-" + j);
                        }