android.widget.ImageView.setActivated()方法的使用及代码示例

x33g5p2x  于2022-01-20 转载在 其他  
字(2.1k)|赞(0)|评价(0)|浏览(244)

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

ImageView.setActivated介绍

暂无

代码示例

代码示例来源:origin: QuickBlox/ChatMessagesAdapter-android

private void setPlayStateIcon() {
  iconPlayPauseView.setActivated(false);
  iconPlayPauseView.setImageState(STATE_SET_PLAY, true);
}

代码示例来源:origin: QuickBlox/ChatMessagesAdapter-android

private void setPauseStateIcon() {
  iconPlayPauseView.setActivated(true);
  iconPlayPauseView.setImageState(STATE_SET_PAUSE, true);
}

代码示例来源:origin: NordicSemiconductor/Android-nRF-Toolbox

@Override
  public View getView(final int position, final View convertView, final ViewGroup parent) {
    View view = convertView;
    if (view == null) {
      view = LayoutInflater.from(getActivity()).inflate(R.layout.feature_uart_dialog_edit_icon, parent, false);
    }
    final ImageView image = (ImageView) view;
    image.setImageLevel(position);
    image.setActivated(position == mActiveIcon && mActiveCheckBox.isChecked());
    return view;
  }
}

代码示例来源:origin: derry/delion

private void configureExpandedCollapsed(boolean isExpanded) {
  String description = getResources().getString(isExpanded
      ? R.string.ntp_recent_tabs_accessibility_expanded_group
      : R.string.ntp_recent_tabs_accessibility_collapsed_group);
  mExpandCollapseIcon.setContentDescription(description);
  int level = isExpanded ? DRAWABLE_LEVEL_EXPANDED : DRAWABLE_LEVEL_COLLAPSED;
  mExpandCollapseIcon.getDrawable().setLevel(level);
  mDeviceIcon.setActivated(isExpanded);
  mDeviceLabel.setTextColor(isExpanded
      ? mDeviceLabelExpandedColor
      : mDeviceLabelCollapsedColor);
  mTimeLabel.setTextColor(isExpanded ? mTimeLabelExpandedColor : mTimeLabelCollapsedColor);
}

代码示例来源:origin: QuickBlox/ChatMessagesAdapter-android

public void clickIconPlayPauseView() {
  if(iconPlayPauseView != null) {
    if (!iconPlayPauseView.isActivated()) {
      iconPlayPauseView.setImageState(STATE_SET_PAUSE, true);
      performPlayClick();
    } else {
      iconPlayPauseView.setImageState(STATE_SET_PLAY, true);
      performPauseClick();
    }
    iconPlayPauseView.setActivated(!iconPlayPauseView.isActivated());
  }
}

相关文章

ImageView类方法