android.support.design.widget.TextInputLayout.getPasswordVisibilityToggleDrawable()方法的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(2.6k)|赞(0)|评价(0)|浏览(134)

本文整理了Java中android.support.design.widget.TextInputLayout.getPasswordVisibilityToggleDrawable()方法的一些代码示例,展示了TextInputLayout.getPasswordVisibilityToggleDrawable()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。TextInputLayout.getPasswordVisibilityToggleDrawable()方法的具体详情如下:
包路径:android.support.design.widget.TextInputLayout
类名称:TextInputLayout
方法名:getPasswordVisibilityToggleDrawable

TextInputLayout.getPasswordVisibilityToggleDrawable介绍

暂无

代码示例

代码示例来源:origin: willowtreeapps/Hyperion-Android

@NonNull
  @Override
  public List<ViewAttribute> collect(TextInputLayout view, AttributeTranslator attributeTranslator) {
    List<ViewAttribute> attributes = new ArrayList<>();
    attributes.add(new ViewAttribute<>("PasswordToggleDrawable",
        view.getPasswordVisibilityToggleDrawable()));
    attributes.add(new ViewAttribute<>("PasswordToggleContentDisc",
        nonNull(view.getPasswordVisibilityToggleContentDescription())));
    attributes.add(new ViewAttribute<>("CounterMaxLength", view.getCounterMaxLength()));
    attributes.add(new ViewAttribute<>("Hint", nonNull(view.getHint())));
    attributes.add(new ViewAttribute<>("CounterEnabled", view.isCounterEnabled()));
    attributes.add(new ViewAttribute<>("ErrorEnabled", view.isErrorEnabled()));
    attributes.add(new ViewAttribute<>("HintAnimationEnabled", view.isHintAnimationEnabled()));
    attributes.add(new ViewAttribute<>("HintEnabled", view.isHintEnabled()));
    attributes.add(new ViewAttribute<>("PasswordToggleEnabled",
        view.isPasswordVisibilityToggleEnabled()));
    return attributes;
  }
}

代码示例来源:origin: jbruchanov/AnUitor

@Override
  protected HashMap<String, Object> fillValues(View v, HashMap<String, Object> data, HashMap<String, Object> parentData) {
    super.fillValues(v, data, parentData);

    TextInputLayout view = (TextInputLayout) v;

    data.put("Error", view.getError());
    data.put("Hint", view.getHint());
    data.put("PasswordVisibilityToggleContentDescription", view.getPasswordVisibilityToggleContentDescription());
    data.put("PasswordVisibilityToggleDrawable:", view.getPasswordVisibilityToggleDrawable());
    data.put("Typeface:", view.getTypeface());
    data.put("IsCounterEnabled", view.isCounterEnabled());
    data.put("IsErrorEnabled", view.isErrorEnabled());
    data.put("IsHintAnimationEnabled", view.isHintAnimationEnabled());
    data.put("IsHintEnabled", view.isHintEnabled());
    data.put("IsPasswordVisibilityToggleEnabled", view.isPasswordVisibilityToggleEnabled());

    return data;
  }
}

相关文章