![]() |
#2
leetee2016-08-30 09:55
|
private static final String imgDir = "F:\\Java\\游戏\\LLK\\图片";
static {
try {
File dir = new File(imgDir);
File[] imgFiles = dir.listFiles(new FilenameFilter() {
public boolean accept(File dir, String name) {
return name.toLowerCase().endsWith(".jpg");
}
});
for (int i = 0; i <15; i++) {
icons[i] = new ImageIcon(imgFiles[i].getAbsolutePath());
//System.out.println(i+" "+icons[i]);
}
} catch (Exception e) {
e.printStackTrace();
}
}
只有本站会员才能查看附件,请 登录
只有本站会员才能查看附件,请 登录