Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTom Schindl2014-11-04 09:40:41 +0000
committerTom Schindl2014-11-04 09:40:41 +0000
commit487f86fbbce0c8025a94afd6463f1d5b47fd0d4f (patch)
tree5d69bb5fc921225ff3139ebaf1983bc8f43e7776
parent01953941ed4b8ade7031485a74550fd649fd6053 (diff)
downloadorg.eclipse.efxclipse-487f86fbbce0c8025a94afd6463f1d5b47fd0d4f.tar.gz
org.eclipse.efxclipse-487f86fbbce0c8025a94afd6463f1d5b47fd0d4f.tar.xz
org.eclipse.efxclipse-487f86fbbce0c8025a94afd6463f1d5b47fd0d4f.zip
Bug 449895 - fix JavaDoc warnings
-rw-r--r--bundles/runtime/org.eclipse.fx.core.di/src/org/eclipse/fx/core/di/ScopedObjectFactory.java14
-rw-r--r--bundles/runtime/org.eclipse.fx.core/src/org/eclipse/fx/core/text/AbstractTextRegistry.java2
-rwxr-xr-xbundles/runtime/org.eclipse.fx.osgi.util/src/org/eclipse/fx/osgi/util/OSGiFXMLLoader.java15
-rw-r--r--bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/PositionMarker.java42
-rw-r--r--bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/TabOutlineMarker.java47
-rw-r--r--bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/sceneviewer/Viewer3d.java55
6 files changed, 74 insertions, 101 deletions
diff --git a/bundles/runtime/org.eclipse.fx.core.di/src/org/eclipse/fx/core/di/ScopedObjectFactory.java b/bundles/runtime/org.eclipse.fx.core.di/src/org/eclipse/fx/core/di/ScopedObjectFactory.java
index 8751c8dde..a71921283 100644
--- a/bundles/runtime/org.eclipse.fx.core.di/src/org/eclipse/fx/core/di/ScopedObjectFactory.java
+++ b/bundles/runtime/org.eclipse.fx.core.di/src/org/eclipse/fx/core/di/ScopedObjectFactory.java
@@ -25,26 +25,28 @@ public interface ScopedObjectFactory {
/**
* Create a new instance of the class
- *
+ *
* @param c
* the class
+ * @param <C>
+ * the type
* @return the instance
*/
public <C> C newInstance(@NonNull Class<@NonNull C> c);
/**
* Create a child of the scoped object factory
- *
+ *
* @param name
* the name
- *
+ *
* @return the child
*/
public @NonNull ScopedObjectFactory createChild(@NonNull String name);
/**
* Push a new value
- *
+ *
* @param key
* the key
* @param value
@@ -54,7 +56,7 @@ public interface ScopedObjectFactory {
/**
* Push a new value
- *
+ *
* @param key
* the key
* @param value
@@ -66,7 +68,7 @@ public interface ScopedObjectFactory {
/**
* Invoke a method annotated with {@link Invoke}
- *
+ *
* @param instance
* the instance on which the method is invoked
* @param <O>
diff --git a/bundles/runtime/org.eclipse.fx.core/src/org/eclipse/fx/core/text/AbstractTextRegistry.java b/bundles/runtime/org.eclipse.fx.core/src/org/eclipse/fx/core/text/AbstractTextRegistry.java
index 07b54f8e3..3d285e594 100644
--- a/bundles/runtime/org.eclipse.fx.core/src/org/eclipse/fx/core/text/AbstractTextRegistry.java
+++ b/bundles/runtime/org.eclipse.fx.core/src/org/eclipse/fx/core/text/AbstractTextRegistry.java
@@ -49,7 +49,7 @@ public class AbstractTextRegistry<M> {
* private MessageHandler handler; // Subclass of AbstractMessageRegistry
*
* TitledPane tb = new TitledPane();
- * handler.register(tb::setText, (m) -> m.PreferenceView_Title);
+ * handler.register(tb::setText, (m) -&gt; m.PreferenceView_Title);
* </pre>
*
* @param consumer
diff --git a/bundles/runtime/org.eclipse.fx.osgi.util/src/org/eclipse/fx/osgi/util/OSGiFXMLLoader.java b/bundles/runtime/org.eclipse.fx.osgi.util/src/org/eclipse/fx/osgi/util/OSGiFXMLLoader.java
index 37dfa3c08..b883a1836 100755
--- a/bundles/runtime/org.eclipse.fx.osgi.util/src/org/eclipse/fx/osgi/util/OSGiFXMLLoader.java
+++ b/bundles/runtime/org.eclipse.fx.osgi.util/src/org/eclipse/fx/osgi/util/OSGiFXMLLoader.java
@@ -106,6 +106,7 @@ public class OSGiFXMLLoader {
* the loaded root object type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O> O load(@NonNull Bundle bundle, @NonNull String bundleRelativeFxmlPath, @Nullable ResourceBundle resourceBundle, @Nullable BuilderFactory builderFactory) throws IOException {
URL url = bundle.getResource(bundleRelativeFxmlPath);
@@ -133,6 +134,7 @@ public class OSGiFXMLLoader {
* the loaded controller type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O, C> FXMLData<O, C> loadWithController(@NonNull Bundle bundle, @NonNull String bundleRelativeFxmlPath, @Nullable ResourceBundle resourceBundle, @Nullable BuilderFactory builderFactory) throws IOException {
URL url = bundle.getResource(bundleRelativeFxmlPath);
@@ -157,6 +159,7 @@ public class OSGiFXMLLoader {
* the loaded root object type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O> O load(@NonNull ClassLoader classloader, @NonNull URL url, @Nullable ResourceBundle resourceBundle, @Nullable BuilderFactory builderFactory) throws IOException {
return load(classloader, url, resourceBundle, builderFactory, null);
@@ -180,6 +183,7 @@ public class OSGiFXMLLoader {
* the loaded controller type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O, C> FXMLData<O, C> loadWithController(@NonNull ClassLoader classloader, @NonNull URL url, @Nullable ResourceBundle resourceBundle, @Nullable BuilderFactory builderFactory) throws IOException {
return loadWithController(classloader, url, null, resourceBundle, builderFactory, null);
@@ -202,6 +206,7 @@ public class OSGiFXMLLoader {
* the loaded root object type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O> O load(@NonNull Class<?> requester, @NonNull String relativeFxmlPath, @Nullable ResourceBundle resourceBundle, @Nullable BuilderFactory builderFactory, @Nullable Callback<Class<?>, Object> controllerFactory) throws IOException {
URL url = requester.getResource(relativeFxmlPath);
@@ -231,6 +236,7 @@ public class OSGiFXMLLoader {
* the loaded controller type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O, C> FXMLData<O, C> loadWithController(@NonNull Class<?> requester, @NonNull String relativeFxmlPath, @Nullable ResourceBundle resourceBundle, @Nullable BuilderFactory builderFactory, @Nullable Callback<Class<?>, Object> controllerFactory) throws IOException {
URL url = requester.getResource(relativeFxmlPath);
@@ -257,6 +263,7 @@ public class OSGiFXMLLoader {
* the loaded root object type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O> O load(@NonNull Bundle bundle, @NonNull String bundleRelativeFxmlPath, @Nullable ResourceBundle resourceBundle, @Nullable BuilderFactory builderFactory, @Nullable Callback<Class<?>, Object> controllerFactory) throws IOException {
URL url = bundle.getResource(bundleRelativeFxmlPath);
@@ -286,6 +293,7 @@ public class OSGiFXMLLoader {
* the loaded controller type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O, C> FXMLData<O, C> loadWithController(@NonNull Bundle bundle, @NonNull String bundleRelativeFxmlPath, @Nullable ResourceBundle resourceBundle, @Nullable BuilderFactory builderFactory, @Nullable Callback<Class<?>, Object> controllerFactory) throws IOException {
URL url = bundle.getResource(bundleRelativeFxmlPath);
@@ -312,6 +320,7 @@ public class OSGiFXMLLoader {
* the loaded root object type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O> O load(@NonNull final ClassLoader classloader, @NonNull URL url, @Nullable ResourceBundle resourceBundle, @Nullable final BuilderFactory builderFactory, @Nullable Callback<Class<?>, Object> controllerFactory) throws IOException {
return OSGiFXMLLoader.<O, Object> loadWithController(classloader, url, null, resourceBundle, builderFactory, controllerFactory).node;
@@ -336,6 +345,7 @@ public class OSGiFXMLLoader {
* the input stream to load from
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
public static <O> O load(@NonNull final ClassLoader classloader, @Nullable URL url, @NonNull InputStream stream, @Nullable ResourceBundle resourceBundle, @Nullable final BuilderFactory builderFactory, @Nullable Callback<Class<?>, Object> controllerFactory) throws IOException {
return OSGiFXMLLoader.<O, Object> loadWithController(classloader, url, stream, resourceBundle, builderFactory, controllerFactory).node;
@@ -361,9 +371,9 @@ public class OSGiFXMLLoader {
* the loaded controller type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
- public static <O, C> FXMLData<O, C> loadWithController(@NonNull final ClassLoader classloader, @Nullable URL url, @Nullable ResourceBundle resourceBundle, @Nullable final BuilderFactory builderFactory, @Nullable Callback<Class<?>, Object> controllerFactory)
- throws IOException {
+ public static <O, C> FXMLData<O, C> loadWithController(@NonNull final ClassLoader classloader, @Nullable URL url, @Nullable ResourceBundle resourceBundle, @Nullable final BuilderFactory builderFactory, @Nullable Callback<Class<?>, Object> controllerFactory) throws IOException {
return loadWithController(classloader, url, null, resourceBundle, builderFactory, controllerFactory);
}
@@ -389,6 +399,7 @@ public class OSGiFXMLLoader {
* the loaded controller type
* @return the created scene graph
* @throws IOException
+ * thrown when the FXML could not be loaded
*/
@SuppressWarnings("unchecked")
public static <O, C> FXMLData<O, C> loadWithController(@NonNull final ClassLoader classloader, @Nullable URL url, @Nullable InputStream stream, @Nullable ResourceBundle resourceBundle, @Nullable final BuilderFactory builderFactory, @Nullable Callback<Class<?>, Object> controllerFactory)
diff --git a/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/PositionMarker.java b/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/PositionMarker.java
index 097d13e18..1f9513301 100644
--- a/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/PositionMarker.java
+++ b/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/PositionMarker.java
@@ -89,15 +89,11 @@ public final class PositionMarker extends Group {
/**
* The property
- * <table>
- * <tr>
- * <td>The default value is Color.rgb(0, 139, 255)</td>
- * <td><div style=
- * "background-color: rgb(0, 139, 255); border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;"
- * ></div></td>
- * </tr>
- * </table>
- *
+ * <p>
+ * The default color Color.rgb(0, 139, 255) <span style=
+ * "background-color: rgb(0, 139, 255); color: rgb(0, 139, 255); border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;">__</span>
+ * </p>
+ *
* @return the fill property of the marker
*/
public @NonNull ObjectProperty<@NonNull Paint> fillProperty() {
@@ -106,15 +102,11 @@ public final class PositionMarker extends Group {
/**
* Set the fill of the marker
- * <table>
- * <tr>
- * <td>The default value is Color.rgb(0, 139, 255)</td>
- * <td><div style=
- * "background-color: rgb(0, 139, 255); border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;"
- * ></div></td>
- * </tr>
- * </table>
- *
+ * <p>
+ * The default color Color.rgb(0, 139, 255) <span style=
+ * "background-color: rgb(0, 139, 255); color: rgb(0, 139, 255); border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;">__</span>
+ * </p>
+ *
* @param fill
* the new fill
*/
@@ -124,15 +116,11 @@ public final class PositionMarker extends Group {
/**
* Access the current fill
- * <table>
- * <tr>
- * <td>The default value is Color.rgb(0, 139, 255)</td>
- * <td><div style=
- * "background-color: rgb(0, 139, 255); border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;"
- * ></div></td>
- * </tr>
- * </table>
- *
+ * <p>
+ * The default color Color.rgb(0, 139, 255) <span style=
+ * "background-color: rgb(0, 139, 255); color: rgb(0, 139, 255); border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;">__</span>
+ * </p>
+ *
* @return the current fill
*/
public @NonNull Paint getFill() {
diff --git a/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/TabOutlineMarker.java b/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/TabOutlineMarker.java
index 0eb89da77..cc397ca1e 100644
--- a/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/TabOutlineMarker.java
+++ b/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/markers/TabOutlineMarker.java
@@ -44,7 +44,7 @@ public final class TabOutlineMarker extends Group {
/**
* Create a new tab outline
- *
+ *
* @param containerBounds
* the bounds of the container
* @param referenceBounds
@@ -62,7 +62,7 @@ public final class TabOutlineMarker extends Group {
/**
* Update the tab outline
- *
+ *
* @param containerBounds
* the bounds of the container
* @param referenceBounds
@@ -138,15 +138,12 @@ public final class TabOutlineMarker extends Group {
/**
* The fill property
- * <table>
- * <tr>
- * <td>The default value is {@link Color#ORANGE}</td>
- * <td><div style=
- * "background-color: orange; border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;"
- * ></div></td>
- * </tr>
- * </table>
- *
+ *
+ * <p>
+ * The default color {@link Color#ORANGE} <span style=
+ * "background-color: orange; color: orange; border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;">__</span>
+ * </p>
+ *
* @return the property
*/
public @NonNull ObjectProperty<@NonNull Paint> fillProperty() {
@@ -155,15 +152,11 @@ public final class TabOutlineMarker extends Group {
/**
* Set a new fill
- * <table>
- * <tr>
- * <td>The default value is {@link Color#ORANGE}</td>
- * <td><div style=
- * "background-color: orange; border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;"
- * ></div></td>
- * </tr>
- * </table>
- *
+ * <p>
+ * The default color {@link Color#ORANGE} <span style=
+ * "background-color: orange; color: orange; border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;">__</span>
+ * </p>
+ *
* @param fill
* the fill
*/
@@ -173,15 +166,11 @@ public final class TabOutlineMarker extends Group {
/**
* Get the current fill
- * <table>
- * <tr>
- * <td>The default value is {@link Color#ORANGE}</td>
- * <td><div style=
- * "background-color: orange; border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;"
- * ></div></td>
- * </tr>
- * </table>
- *
+ * <p>
+ * The default color {@link Color#ORANGE} <span style=
+ * "background-color: orange; color: orange; border-width: 1px; border-color: black; border-style: solid; width: 15; height: 15;">__</span>
+ * </p>
+ *
* @return the current fill
*/
public @NonNull Paint getFill() {
diff --git a/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/sceneviewer/Viewer3d.java b/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/sceneviewer/Viewer3d.java
index c865ddd2a..4392b49bb 100644
--- a/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/sceneviewer/Viewer3d.java
+++ b/bundles/runtime/org.eclipse.fx.ui.controls/src/org/eclipse/fx/ui/controls/sceneviewer/Viewer3d.java
@@ -52,8 +52,7 @@ import org.eclipse.jdt.annotation.Nullable;
public final class Viewer3d extends Pane {
private SubScene scene;
private final Rotate cameraXRotation = new Rotate(0, 0, 0, 0, Rotate.X_AXIS);
- private final Rotate cameraYRotation = new Rotate(-35, 0, 0, 0,
- Rotate.Y_AXIS);
+ private final Rotate cameraYRotation = new Rotate(-35, 0, 0, 0, Rotate.Y_AXIS);
private final Translate cameraPosition = new Translate(0, 0, -100);
private Camera camera;
private double dragStartX, dragStartY, dragStartRotateX, dragStartRotateY;
@@ -63,17 +62,13 @@ public final class Viewer3d extends Pane {
@SuppressWarnings("null")
@NonNull
- private final ObservableList<@NonNull Node> selectedNodes = FXCollections
- .observableArrayList();
+ private final ObservableList<@NonNull Node> selectedNodes = FXCollections.observableArrayList();
@NonNull
- private final ObjectProperty<@Nullable Node> hoverNode = new SimpleObjectProperty<>(
- this, "hoverNode"); //$NON-NLS-1$
+ private final ObjectProperty<@Nullable Node> hoverNode = new SimpleObjectProperty<>(this, "hoverNode"); //$NON-NLS-1$
@NonNull
- private final ObjectProperty<@Nullable Node> contentProperty = new SimpleObjectProperty<>(
- this, "content"); //$NON-NLS-1$
+ private final ObjectProperty<@Nullable Node> contentProperty = new SimpleObjectProperty<>(this, "content"); //$NON-NLS-1$
@NonNull
- private final BooleanProperty animated = new SimpleBooleanProperty(this,
- "rotate"); //$NON-NLS-1$
+ private final BooleanProperty animated = new SimpleBooleanProperty(this, "rotate"); //$NON-NLS-1$
/**
* Create a new 3d viewer
@@ -82,8 +77,7 @@ public final class Viewer3d extends Pane {
this.contentGroup = new Group();
this.contentGroup.getTransforms().add(this.contentScale);
Group root = new Group(this.contentGroup);
- this.scene = new SubScene(root, -1, -1, true,
- SceneAntialiasing.BALANCED);
+ this.scene = new SubScene(root, -1, -1, true, SceneAntialiasing.BALANCED);
this.scene.setManaged(false);
this.camera = setupCamera();
this.scene.setCamera(this.camera);
@@ -159,12 +153,9 @@ public final class Viewer3d extends Pane {
* the percentage to zoom out
*/
public void zoomIn(double percentage) {
- this.contentScale.setX(this.contentScale.getX()
- + this.contentScale.getX() * percentage);
- this.contentScale.setY(this.contentScale.getY()
- + this.contentScale.getY() * percentage);
- this.contentScale.setZ(this.contentScale.getZ()
- + this.contentScale.getZ() * percentage);
+ this.contentScale.setX(this.contentScale.getX() + this.contentScale.getX() * percentage);
+ this.contentScale.setY(this.contentScale.getY() + this.contentScale.getY() * percentage);
+ this.contentScale.setZ(this.contentScale.getZ() + this.contentScale.getZ() * percentage);
}
/**
@@ -174,12 +165,9 @@ public final class Viewer3d extends Pane {
* the percentage to zoom in
*/
public void zoomOut(double percentage) {
- this.contentScale.setX(this.contentScale.getX()
- - this.contentScale.getX() * percentage);
- this.contentScale.setY(this.contentScale.getY()
- - this.contentScale.getY() * percentage);
- this.contentScale.setZ(this.contentScale.getZ()
- - this.contentScale.getZ() * percentage);
+ this.contentScale.setX(this.contentScale.getX() - this.contentScale.getX() * percentage);
+ this.contentScale.setY(this.contentScale.getY() - this.contentScale.getY() * percentage);
+ this.contentScale.setZ(this.contentScale.getZ() - this.contentScale.getZ() * percentage);
}
/**
@@ -199,6 +187,7 @@ public final class Viewer3d extends Pane {
* @param duration
* the duration
* @param r
+ * consumer called at the end of the zooming
*/
public void zoomTo(double target, Duration duration, Consumer<ActionEvent> r) {
if (duration != null) {
@@ -309,20 +298,15 @@ public final class Viewer3d extends Pane {
} else if (event.getEventType() == MouseEvent.MOUSE_DRAGGED) {
double xDelta = event.getSceneX() - this.dragStartX;
double yDelta = event.getSceneY() - this.dragStartY;
- this.cameraXRotation.setAngle(this.dragStartRotateX
- - (yDelta * 0.7));
- this.cameraYRotation.setAngle(this.dragStartRotateY
- + (xDelta * 0.7));
+ this.cameraXRotation.setAngle(this.dragStartRotateX - (yDelta * 0.7));
+ this.cameraYRotation.setAngle(this.dragStartRotateY + (xDelta * 0.7));
}
}
private void zoomHandler(ScrollEvent event) {
- this.contentScale.setX(this.contentScale.getX() + event.getDeltaY()
- * 0.01);
- this.contentScale.setY(this.contentScale.getY() + event.getDeltaY()
- * 0.01);
- this.contentScale.setZ(this.contentScale.getZ() + event.getDeltaY()
- * 0.01);
+ this.contentScale.setX(this.contentScale.getX() + event.getDeltaY() * 0.01);
+ this.contentScale.setY(this.contentScale.getY() + event.getDeltaY() * 0.01);
+ this.contentScale.setZ(this.contentScale.getZ() + event.getDeltaY() * 0.01);
}
private void updateSize() {
@@ -342,8 +326,7 @@ public final class Viewer3d extends Pane {
private Camera setupCamera() {
PerspectiveCamera camera = new PerspectiveCamera();
- camera.getTransforms().addAll(this.cameraXRotation,
- this.cameraYRotation, this.cameraPosition);
+ camera.getTransforms().addAll(this.cameraXRotation, this.cameraYRotation, this.cameraPosition);
return camera;
}

Back to the top