android.widget.TextView.setContentDescription()方法的使用及代码示例

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

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

TextView.setContentDescription介绍

暂无

代码示例

代码示例来源:origin: wdullaer/MaterialDateTimePicker

private void updateAmPmDisplay(int amOrPm) {
  if (mVersion == Version.VERSION_2) {
    if (amOrPm == AM) {
      mAmTextView.setTextColor(mSelectedColor);
      mPmTextView.setTextColor(mUnselectedColor);
      Utils.tryAccessibilityAnnounce(mTimePicker, mAmText);
    } else {
      mAmTextView.setTextColor(mUnselectedColor);
      mPmTextView.setTextColor(mSelectedColor);
      Utils.tryAccessibilityAnnounce(mTimePicker, mPmText);
    }
  } else {
    if (amOrPm == AM) {
      mPmTextView.setText(mAmText);
      Utils.tryAccessibilityAnnounce(mTimePicker, mAmText);
      mPmTextView.setContentDescription(mAmText);
    } else if (amOrPm == PM){
      mPmTextView.setText(mPmText);
      Utils.tryAccessibilityAnnounce(mTimePicker, mPmText);
      mPmTextView.setContentDescription(mPmText);
    } else {
      mPmTextView.setText(mDoublePlaceholderText);
    }
  }
}

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

forecastAdapterViewHolder.descriptionView.setContentDescription(descriptionA11y);
forecastAdapterViewHolder.highTempView.setContentDescription(highA11y);
forecastAdapterViewHolder.lowTempView.setContentDescription(lowA11y);

代码示例来源:origin: udacity/ud851-Sunshine

mDetailBinding.primaryInfo.weatherDescription.setContentDescription(descriptionA11y);
mDetailBinding.primaryInfo.highTemperature.setContentDescription(highA11y);
mDetailBinding.primaryInfo.lowTemperature.setContentDescription(lowA11y);
mDetailBinding.extraDetails.humidity.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.humidityLabel.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.windMeasurement.setContentDescription(windA11y);
mDetailBinding.extraDetails.windLabel.setContentDescription(windA11y);
mDetailBinding.extraDetails.pressure.setContentDescription(pressureA11y);
mDetailBinding.extraDetails.pressureLabel.setContentDescription(pressureA11y);

代码示例来源:origin: udacity/ud851-Sunshine

mDetailBinding.primaryInfo.weatherDescription.setContentDescription(descriptionA11y);
mDetailBinding.primaryInfo.highTemperature.setContentDescription(highA11y);
mDetailBinding.primaryInfo.lowTemperature.setContentDescription(lowA11y);
mDetailBinding.extraDetails.humidity.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.humidityLabel.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.windMeasurement.setContentDescription(windA11y);
mDetailBinding.extraDetails.windLabel.setContentDescription(windA11y);
mDetailBinding.extraDetails.pressure.setContentDescription(pressureA11y);
mDetailBinding.extraDetails.pressureLabel.setContentDescription(pressureA11y);

代码示例来源:origin: udacity/ud851-Sunshine

mDetailBinding.primaryInfo.weatherDescription.setContentDescription(descriptionA11y);
mDetailBinding.primaryInfo.highTemperature.setContentDescription(highA11y);
mDetailBinding.primaryInfo.lowTemperature.setContentDescription(lowA11y);
mDetailBinding.extraDetails.humidity.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.humidityLabel.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.windMeasurement.setContentDescription(windA11y);
mDetailBinding.extraDetails.windLabel.setContentDescription(windA11y);
mDetailBinding.extraDetails.pressure.setContentDescription(pressureA11y);
mDetailBinding.extraDetails.pressureLabel.setContentDescription(pressureA11y);

代码示例来源:origin: udacity/ud851-Sunshine

mDetailBinding.primaryInfo.weatherDescription.setContentDescription(descriptionA11y);
mDetailBinding.primaryInfo.highTemperature.setContentDescription(highA11y);
mDetailBinding.primaryInfo.lowTemperature.setContentDescription(lowA11y);
mDetailBinding.extraDetails.humidity.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.humidityLabel.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.windMeasurement.setContentDescription(windA11y);
mDetailBinding.extraDetails.windLabel.setContentDescription(windA11y);
mDetailBinding.extraDetails.pressure.setContentDescription(pressureA11y);
mDetailBinding.extraDetails.pressureLabel.setContentDescription(pressureA11y);

代码示例来源:origin: udacity/ud851-Sunshine

mDetailBinding.primaryInfo.weatherDescription.setContentDescription(descriptionA11y);
mDetailBinding.primaryInfo.highTemperature.setContentDescription(highA11y);
mDetailBinding.primaryInfo.lowTemperature.setContentDescription(lowA11y);
mDetailBinding.extraDetails.humidity.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.humidityLabel.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.windMeasurement.setContentDescription(windA11y);
mDetailBinding.extraDetails.windLabel.setContentDescription(windA11y);
mDetailBinding.extraDetails.pressure.setContentDescription(pressureA11y);
mDetailBinding.extraDetails.pressureLabel.setContentDescription(pressureA11y);

代码示例来源:origin: udacity/ud851-Sunshine

mDetailBinding.primaryInfo.weatherDescription.setContentDescription(descriptionA11y);
mDetailBinding.primaryInfo.highTemperature.setContentDescription(highA11y);
mDetailBinding.primaryInfo.lowTemperature.setContentDescription(lowA11y);
mDetailBinding.extraDetails.humidity.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.humidityLabel.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.windMeasurement.setContentDescription(windA11y);
mDetailBinding.extraDetails.windLabel.setContentDescription(windA11y);
mDetailBinding.extraDetails.pressure.setContentDescription(pressureA11y);
mDetailBinding.extraDetails.pressureLabel.setContentDescription(pressureA11y);

代码示例来源:origin: udacity/ud851-Sunshine

mDetailBinding.primaryInfo.weatherDescription.setContentDescription(descriptionA11y);
mDetailBinding.primaryInfo.highTemperature.setContentDescription(highA11y);
mDetailBinding.primaryInfo.lowTemperature.setContentDescription(lowA11y);
mDetailBinding.extraDetails.humidity.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.humidityLabel.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.windMeasurement.setContentDescription(windA11y);
mDetailBinding.extraDetails.windLabel.setContentDescription(windA11y);
mDetailBinding.extraDetails.pressure.setContentDescription(pressureA11y);
mDetailBinding.extraDetails.pressureLabel.setContentDescription(pressureA11y);

代码示例来源:origin: udacity/ud851-Sunshine

mDetailBinding.primaryInfo.weatherDescription.setContentDescription(descriptionA11y);
mDetailBinding.primaryInfo.highTemperature.setContentDescription(highA11y);
mDetailBinding.primaryInfo.lowTemperature.setContentDescription(lowA11y);
mDetailBinding.extraDetails.humidity.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.humidityLabel.setContentDescription(humidityA11y);
mDetailBinding.extraDetails.windMeasurement.setContentDescription(windA11y);
mDetailBinding.extraDetails.windLabel.setContentDescription(windA11y);
mDetailBinding.extraDetails.pressure.setContentDescription(pressureA11y);
mDetailBinding.extraDetails.pressureLabel.setContentDescription(pressureA11y);

相关文章

TextView类方法