]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.document.ui/src/org/simantics/document/ui/DocumentView.java
Fixed all line endings of the repository
[simantics/platform.git] / bundles / org.simantics.document.ui / src / org / simantics / document / ui / DocumentView.java
index 025b88b0808348357691bbb9c0f169f3eb65c7f6..0d7973f6af728ddf0fa02096e6d08a91ecd8fd03 100644 (file)
@@ -1,67 +1,67 @@
-/*******************************************************************************\r
- * Copyright (c) 2007, 2012 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.document.ui;\r
-\r
-import org.eclipse.jface.action.Action;\r
-import org.eclipse.jface.action.IAction;\r
-import org.eclipse.swt.widgets.Composite;\r
-import org.eclipse.ui.IWorkbenchPart;\r
-import org.simantics.ui.workbench.IPropertyPage;\r
-import org.simantics.utils.ui.BundleUtils;\r
-import org.simantics.views.swt.ModelledView;\r
-\r
-/**\r
- * @author Antti Villberg\r
- */\r
-public class DocumentView extends ModelledView {\r
-\r
-    private boolean pinSelection = false;\r
-\r
-    @Override\r
-    protected String configurationURI() {\r
-        return DocumentUIResource.URIs.View;\r
-    }\r
-\r
-    @Override\r
-    protected IPropertyPage getPropertyPage() {\r
-        return null;\r
-    }\r
-\r
-    @Override\r
-    protected void inputChanged(IWorkbenchPart provider, Object input) {\r
-        if (pinSelection)\r
-            return;\r
-        super.inputChanged(provider, input);\r
-    }\r
-\r
-    @Override\r
-    public void createPartControl(Composite parent) {\r
-        super.createPartControl(parent);\r
-        getViewSite().getActionBars().getToolBarManager().add(new PinSelection());\r
-    }\r
-\r
-    private class PinSelection extends Action {\r
-        public PinSelection() {\r
-            super("Pin Selection", IAction.AS_CHECK_BOX);\r
-            setImageDescriptor(\r
-                    BundleUtils.getImageDescriptorFromPlugin(\r
-                            "org.eclipse.ui",\r
-                            "icons/full/etool16/pin_editor.png"));\r
-        }\r
-\r
-        @Override\r
-        public void run() {\r
-            pinSelection = isChecked();\r
-        }\r
-    }\r
-\r
-}\r
+/*******************************************************************************
+ * Copyright (c) 2007, 2012 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.document.ui;
+
+import org.eclipse.jface.action.Action;
+import org.eclipse.jface.action.IAction;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.ui.IWorkbenchPart;
+import org.simantics.ui.workbench.IPropertyPage;
+import org.simantics.utils.ui.BundleUtils;
+import org.simantics.views.swt.ModelledView;
+
+/**
+ * @author Antti Villberg
+ */
+public class DocumentView extends ModelledView {
+
+    private boolean pinSelection = false;
+
+    @Override
+    protected String configurationURI() {
+        return DocumentUIResource.URIs.View;
+    }
+
+    @Override
+    protected IPropertyPage getPropertyPage() {
+        return null;
+    }
+
+    @Override
+    protected void inputChanged(IWorkbenchPart provider, Object input) {
+        if (pinSelection)
+            return;
+        super.inputChanged(provider, input);
+    }
+
+    @Override
+    public void createPartControl(Composite parent) {
+        super.createPartControl(parent);
+        getViewSite().getActionBars().getToolBarManager().add(new PinSelection());
+    }
+
+    private class PinSelection extends Action {
+        public PinSelection() {
+            super("Pin Selection", IAction.AS_CHECK_BOX);
+            setImageDescriptor(
+                    BundleUtils.getImageDescriptorFromPlugin(
+                            "org.eclipse.ui",
+                            "icons/full/etool16/pin_editor.png"));
+        }
+
+        @Override
+        public void run() {
+            pinSelection = isChecked();
+        }
+    }
+
+}