X-Git-Url: https://git.argeo.org/?a=blobdiff_plain;f=swt%2Forg.argeo.app.ui%2Fsrc%2Forg%2Fargeo%2Fapp%2Fui%2FSuiteUiUtils.java;h=504e8eda75c87f6ea07a5b91508cad0c93bc35c0;hb=b412aef36bda3f0a9e5ed73ab2206db0f819afa9;hp=2ba43145cbe245d1b29f524ddea4eccc2c238584;hpb=2362aefd312e04eea437824f37cb6e63389cd361;p=gpl%2Fargeo-suite.git diff --git a/swt/org.argeo.app.ui/src/org/argeo/app/ui/SuiteUiUtils.java b/swt/org.argeo.app.ui/src/org/argeo/app/ui/SuiteUiUtils.java index 2ba4314..504e8ed 100644 --- a/swt/org.argeo.app.ui/src/org/argeo/app/ui/SuiteUiUtils.java +++ b/swt/org.argeo.app.ui/src/org/argeo/app/ui/SuiteUiUtils.java @@ -71,6 +71,10 @@ public class SuiteUiUtils { } } + public static Label addFormLabel(Composite parent, Localized msg) { + return addFormLabel(parent, msg.lead()); + } + public static Label addFormLabel(Composite parent, String label) { Label lbl = new Label(parent, SWT.WRAP); lbl.setText(label); @@ -238,7 +242,8 @@ public class SuiteUiUtils { boolean test = false; if (test) { try (InputStream in = JcrUtils.getFileAsStream(fileNode); - OutputStream out = Files.newOutputStream(Paths.get("/home/mbaudier/tmp/" + fileNode.getName()));) { + OutputStream out = Files.newOutputStream( + Paths.get(System.getProperty("user.home") + "/tmp/" + fileNode.getName()));) { // BufferedImage img = ImageIO.read(in); // System.out.println(fileNode.getName() + ": width=" + img.getWidth() + ", height=" + img.getHeight()); IOUtils.copy(in, out);