📄 image2.java
字号:
// Decompiled by Jad v1.5.7g. Copyright 2000 Pavel Kouznetsov.
// Jad home page: http://www.geocities.com/SiliconValley/Bridge/8617/jad.html
// Decompiler options: packimports(3) fieldsfirst ansi
import java.io.IOException;
import javax.microedition.lcdui.Graphics;
import javax.microedition.lcdui.Image;
public class Image2
{
public Image image;
public int width;
public int height;
public Image2(String s)
{
try {
image =Image.createImage(s);
width = image.getWidth();
height = image.getHeight();
}
catch (IOException e) {
e.printStackTrace();
}
}
public void draw(Graphics g, int i, int j)
{
g.drawImage(image, i, j, 0);
}
public void drawCenter(Graphics g, int y)
{
g.drawImage(image, (GameScreen.ScreenWidth - width) >> 1, y, 0);
}
public void drawCenterBottom(Graphics g, int x, int y)
{
g.drawImage(image, x - (width >> 1), y - height, 0);
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -