SettingsActivity.java 文件源码

java
阅读 40 收藏 0 点赞 0 评论 0

项目:kibou-game-library 作者:
private void setControls() {
    iconNumber = (Spinner) findViewById(R.id.stIconNumber);

    List<String> spinnerArray = new ArrayList<>();
    spinnerArray.add(String.valueOf(Const.ICONS_SIZE.ICONS_BIG));
    spinnerArray.add(String.valueOf(Const.ICONS_SIZE.ICONS_MEDIUM));
    spinnerArray.add(String.valueOf(Const.ICONS_SIZE.ICONS_LOW));
    spinnerArray.add(String.valueOf(Const.ICONS_SIZE.ICONS_LOWER));
    spinnerArray.add(String.valueOf(Const.ICONS_SIZE.ICONS_LOWEST));
    spinnerArray.add(String.valueOf(Const.ICONS_SIZE.ICONS_LOWESTER));
    spinnerArray.add(String.valueOf(Const.ICONS_SIZE.ICONS_LOWESTEREST));

    ArrayAdapter<String> adapter = new ArrayAdapter<String>(this,
            R.layout.spinner_item, spinnerArray);

    iconNumber.setAdapter(adapter);
    iconNumber.getBackground().setColorFilter(getResources().getColor(R.color.white), PorterDuff.Mode.SRC_ATOP);

    iconNumber.setSelection(selectedPosition, true);

    btnChooseWallpaper = (Button) findViewById(R.id.stWallpaperButton);
    btnChooseWallpaper.setOnClickListener(this);
    btnWallpaperDefault = (Button) findViewById(R.id.stWallpaperButtonDefault);
    btnWallpaperDefault.setOnClickListener(this);
    txtCustomTitle = (EditText) findViewById(R.id.stCustomTitleValue);
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号