-/*******************************************************************************\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
-/*\r
- *\r
- * @author Toni Kalajainen\r
- */\r
-package org.simantics.g2d.image;\r
-\r
-import org.simantics.utils.datastructures.cache.IFactory;\r
-\r
-\r
-/**\r
- * This class contains some built-in images.\r
- * \r
- * Usage example.\r
- * \r
- * Image x = DefaultImages.UNKNOWN.get();\r
- * x.paint();\r
- * ...\r
- * x = null;\r
- *\r
- * @author Toni Kalajainen <toni.kalajainen@vtt.fi>\r
- */\r
-public class DefaultImages { \r
- \r
- public static final IFactory<Image> UNKNOWN2 = get("unknown.png");\r
- public static final IFactory<Image> SVG = get("svg.png");\r
- public static final IFactory<Image> ERROR_DECORATOR = get("error.svg");\r
- public static final IFactory<Image> WARNING_DECORATOR = get("warningDecorator.png");\r
- public static final IFactory<Image> COMPOSITION = get("composition.png");\r
- public static final IFactory<Image> UNKNOWN = get("unknownDocument.svg");\r
- public static final IFactory<Image> WHEEL = get("wheel2.svg"); \r
- public static final IFactory<Image> GRAB = get("grab.png");\r
- public static final IFactory<Image> GRAB32 = get("grab32.png");\r
- public static final IFactory<Image> HAND = get("hand.png");\r
- public static final IFactory<Image> HAND32 = get("hand32.png");\r
- public static final IFactory<Image> HOURGLASS = get("hourglass.svg");\r
-\r
- private static IFactory<Image> get(String filename) {\r
- return \r
- ProviderUtils.reference(\r
- ProviderUtils.cache(\r
- ProviderUtils.rasterize(\r
- ProviderUtils.at(\r
- DefaultImages.class.getResource(filename)\r
- )))); \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
+ *******************************************************************************/
+/*
+ *
+ * @author Toni Kalajainen
+ */
+package org.simantics.g2d.image;
+
+import org.simantics.utils.datastructures.cache.IFactory;
+
+
+/**
+ * This class contains some built-in images.
+ *
+ * Usage example.
+ *
+ * Image x = DefaultImages.UNKNOWN.get();
+ * x.paint();
+ * ...
+ * x = null;
+ *
+ * @author Toni Kalajainen <toni.kalajainen@vtt.fi>
+ */
+public class DefaultImages {
+
+ public static final IFactory<Image> UNKNOWN2 = get("unknown.png");
+ public static final IFactory<Image> SVG = get("svg.png");
+ public static final IFactory<Image> ERROR_DECORATOR = get("error.svg");
+ public static final IFactory<Image> WARNING_DECORATOR = get("warningDecorator.png");
+ public static final IFactory<Image> COMPOSITION = get("composition.png");
+ public static final IFactory<Image> UNKNOWN = get("unknownDocument.svg");
+ public static final IFactory<Image> WHEEL = get("wheel2.svg");
+ public static final IFactory<Image> GRAB = get("grab.png");
+ public static final IFactory<Image> GRAB32 = get("grab32.png");
+ public static final IFactory<Image> HAND = get("hand.png");
+ public static final IFactory<Image> HAND32 = get("hand32.png");
+ public static final IFactory<Image> HOURGLASS = get("hourglass.svg");
+
+ private static IFactory<Image> get(String filename) {
+ return
+ ProviderUtils.reference(
+ ProviderUtils.cache(
+ ProviderUtils.rasterize(
+ ProviderUtils.at(
+ DefaultImages.class.getResource(filename)
+ ))));
+ }
+
+}