编写一个Applet,显示一副图像并配上背景音乐

public class ImageMusic extends Applet{

    Image img;
    public void paint(Graphics g) {
        img=getImage(getCodeBase(),"glm.jpg");
        g.drawImage(img, 10, 10, this);
        play(getCodeBase(),"秋酿.wav");
    }
}
 


猜你喜欢

转载自blog.csdn.net/xxx_1_1/article/details/82498199
今日推荐