行 wallpaperManager.setResource(R.drawable.wall1); エラーが発生します(R.drawable.wall1の赤い線)
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.wallpaper_set);
bSet = (Button) findViewById(R.id.bSetWall);
bSet.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
WallpaperManager wallpaperManager = WallpaperManager.getInstance(WallpaperSet.this);
try {
wallpaperManager.setResource(R.drawable.wall1);
} catch (IOException e) {
e.printStackTrace();
}
}
});
}