]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.ui/src/org/simantics/ui/workbench/TitleUpdater.java
Fixed all line endings of the repository
[simantics/platform.git] / bundles / org.simantics.ui / src / org / simantics / ui / workbench / TitleUpdater.java
index 30328e28a49ce9efe26cd9414b4cb74bf550979b..7cf8ae3b4c943971b3b2b239c2fcc2ab994d0be8 100644 (file)
@@ -1,59 +1,59 @@
-/*******************************************************************************\r
- * Copyright (c) 2007, 2010 Association for Decentralized Information Management\r
- * in Industry THTH ry.\r
- * All rights reserved. This program and the accompanying materials\r
- * are made available under the terms of the Eclipse Public License v1.0\r
- * which accompanies this distribution, and is available at\r
- * http://www.eclipse.org/legal/epl-v10.html\r
- *\r
- * Contributors:\r
- *     VTT Technical Research Centre of Finland - initial API and implementation\r
- *******************************************************************************/\r
-package org.simantics.ui.workbench;\r
-\r
-import java.util.function.Consumer;\r
-import java.util.function.Supplier;\r
-\r
-import org.eclipse.core.runtime.IStatus;\r
-import org.eclipse.core.runtime.Status;\r
-import org.eclipse.swt.widgets.Display;\r
-import org.simantics.db.procedure.Listener;\r
-import org.simantics.ui.internal.Activator;\r
-\r
-/**\r
- * @author Tuukka Lehtonen\r
- */\r
-public class TitleUpdater implements Listener<String> {\r
-\r
-    private final Display           display;\r
-    private final Consumer<String>  callback;\r
-    private final Supplier<Boolean> disposed;\r
-\r
-    public TitleUpdater(Display display, Consumer<String> titleChangedCallback, Supplier<Boolean> disposed) {\r
-        this.display = display;\r
-        this.callback = titleChangedCallback;\r
-        this.disposed = disposed;\r
-    }\r
-\r
-    @Override\r
-    public void execute(final String result) {\r
-        display.asyncExec(new Runnable() {\r
-            @Override\r
-            public void run() {\r
-                if (!isDisposed())\r
-                    callback.accept(result);\r
-            }\r
-        });\r
-    }\r
-\r
-    @Override\r
-    public boolean isDisposed() {\r
-        return disposed.get();\r
-    }\r
-\r
-    @Override\r
-    public void exception(Throwable t) {\r
-        Activator.getDefault().getLog().log(new Status(IStatus.ERROR, Activator.PLUGIN_ID, "Title update failed.", t));\r
-    }\r
-\r
-}\r
+/*******************************************************************************
+ * Copyright (c) 2007, 2010 Association for Decentralized Information Management
+ * in Industry THTH ry.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ *     VTT Technical Research Centre of Finland - initial API and implementation
+ *******************************************************************************/
+package org.simantics.ui.workbench;
+
+import java.util.function.Consumer;
+import java.util.function.Supplier;
+
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.Status;
+import org.eclipse.swt.widgets.Display;
+import org.simantics.db.procedure.Listener;
+import org.simantics.ui.internal.Activator;
+
+/**
+ * @author Tuukka Lehtonen
+ */
+public class TitleUpdater implements Listener<String> {
+
+    private final Display           display;
+    private final Consumer<String>  callback;
+    private final Supplier<Boolean> disposed;
+
+    public TitleUpdater(Display display, Consumer<String> titleChangedCallback, Supplier<Boolean> disposed) {
+        this.display = display;
+        this.callback = titleChangedCallback;
+        this.disposed = disposed;
+    }
+
+    @Override
+    public void execute(final String result) {
+        display.asyncExec(new Runnable() {
+            @Override
+            public void run() {
+                if (!isDisposed())
+                    callback.accept(result);
+            }
+        });
+    }
+
+    @Override
+    public boolean isDisposed() {
+        return disposed.get();
+    }
+
+    @Override
+    public void exception(Throwable t) {
+        Activator.getDefault().getLog().log(new Status(IStatus.ERROR, Activator.PLUGIN_ID, "Title update failed.", t));
+    }
+
+}