Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleans up warnings in jme3-desktop #2244

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions jme3-desktop/src/main/java/com/jme3/app/AppletHarness.java
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public static Applet getApplet(Application app){
return appToApplet.get(app);
}

@SuppressWarnings("unchecked")

private void createCanvas(){
AppSettings settings = new AppSettings(true);

Expand Down Expand Up @@ -107,7 +107,7 @@ private void createCanvas(){
JmeSystem.setLowPermissions(true);

try{
Class clazz = Class.forName(appClass);
Class<?> clazz = Class.forName(appClass);
app = (LegacyApplication) clazz.getDeclaredConstructor().newInstance();
} catch (ClassNotFoundException
| InstantiationException
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,6 @@
import java.awt.Component;

import com.jme3.app.Application;
import com.jme3.app.state.AbstractAppState;
import com.jme3.app.state.AppStateManager;
import com.jme3.system.AWTFrameProcessor;
import com.jme3.system.AWTTaskExecutor;

Expand Down
184 changes: 80 additions & 104 deletions jme3-desktop/src/main/java/com/jme3/cursors/plugins/CursorLoader.java

Large diffs are not rendered by default.

2 changes: 0 additions & 2 deletions jme3-desktop/src/main/java/com/jme3/input/AWTInput.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@
import java.util.Objects;

import com.jme3.app.Application;
import com.jme3.input.Input;
import com.jme3.input.RawInputListener;
import com.jme3.system.AWTContext;
import com.jme3.system.AWTTaskExecutor;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -185,10 +185,7 @@ public AWTComponentRenderer(Component destination, TransferMode transferMode, Fr
if (frameBuffer != null) {
this.frameBuffer = frameBuffer;
} else {
this.frameBuffer = new FrameBuffer(width, height, 1);
this.frameBuffer.setDepthBuffer(Image.Format.Depth);
this.frameBuffer.setColorBuffer(Image.Format.RGBA8);
this.frameBuffer.setSrgb(true);
this.frameBuffer = AWTUtils.getFrameBuffer(width, height, 1);
}

colorModel = ColorModel.getRGBdefault();
Expand All @@ -203,6 +200,7 @@ public AWTComponentRenderer(Component destination, TransferMode transferMode, Fr

}


/**
* Initialize the component renderer.
* @param renderer the JMonkey {@link Renderer renderer} to use.
Expand Down
Loading
Loading