当前位置: 首页>>代码示例>>Java>>正文


Java SeekBar.setEnabled方法代码示例

本文整理汇总了Java中android.widget.SeekBar.setEnabled方法的典型用法代码示例。如果您正苦于以下问题:Java SeekBar.setEnabled方法的具体用法?Java SeekBar.setEnabled怎么用?Java SeekBar.setEnabled使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在android.widget.SeekBar的用法示例。


在下文中一共展示了SeekBar.setEnabled方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: updateBars

import android.widget.SeekBar; //导入方法依赖的package包/类
private void updateBars()
{
	try
	{
		for (Map.Entry<Short, SeekBar> entry : bars.entrySet())
		{
			short band = entry.getKey();
			SeekBar bar = entry.getValue();
			bar.setEnabled(equalizer.getEnabled());
			short minEQLevel = equalizer.getBandLevelRange()[0];
			bar.setProgress(equalizer.getBandLevel(band) - minEQLevel);
		}
	}
	catch (Exception ex)
	{
		//TODO: Show a dialog
	}
}
 
开发者ID:ultrasonic,项目名称:ultrasonic,代码行数:19,代码来源:EqualizerActivity.java

示例2: findView

import android.widget.SeekBar; //导入方法依赖的package包/类
private void findView() {
    readDrawer = (DrawerLayout) findViewById(R.id.read_drawer);
    readSide = (LinearLayout) findViewById(R.id.read_side);
    readRvSection = (RecyclerView) findViewById(R.id.read_rv_section);
    readView = (PageView) findViewById(R.id.pv_read);
    appBar = (AppBarLayout) findViewById(R.id.appbar);
    readBottom = findViewById(R.id.read_bottom);
    readTvPreChapter = (TextView) findViewById(R.id.read_tv_pre_chapter);
    readSbChapterProgress = (SeekBar) findViewById(R.id.read_sb_chapter_progress);
    readTvNextChapter = (TextView) findViewById(R.id.read_tv_next_chapter);
    readTvCategory = (TextView) findViewById(R.id.read_tv_category);
    readTvNightMode = (TextView) findViewById(R.id.read_tv_night_mode);
    readTvSetting = (TextView) findViewById(R.id.read_tv_setting);
    tvSectionName=findViewById(R.id.tv_section_name);
    readSectionProgress=findViewById(R.id.ll_section_progress);
    readTvSectionProgress=findViewById(R.id.tv_section_progress);
    readSbChapterProgress.setEnabled(false);
}
 
开发者ID:z-chu,项目名称:FriendBook,代码行数:19,代码来源:ReadActivity.java

示例3: lockBrightnessControls

import android.widget.SeekBar; //导入方法依赖的package包/类
private void lockBrightnessControls(boolean lock) {
  SeekBar slider = (SeekBar) findViewById(R.id.slider);
  ListView profileList = (ListView) findViewById(R.id.profile_list);

  // Note: setEnabled() doesn't seem to work with this ListView, nor does
  // calling setEnabled() on the individual children of the ListView.
  // The items become grayed out, but the click handlers are still registered.
  // As a work around, simply hide the entire list view.
  if (lock) {
    profileList.setVisibility(View.GONE);
    slider.setEnabled(false);
  } else {
    profileList.setVisibility(View.VISIBLE);
    slider.setEnabled(true);
  }
}
 
开发者ID:sdrausty,项目名称:buildAPKsApps,代码行数:17,代码来源:BrightnessProfiles.java

示例4: updateView

import android.widget.SeekBar; //导入方法依赖的package包/类
private void updateView() {
    mSwitchBeauty.setImageResource(isOpen ? R.drawable.kai : R.drawable.guan);
    for (SeekBarRow row : seekBarRowList) {
        SeekBar seekBar = row.seekBar;
        seekBar.setEnabled(isOpen);
    }
}
 
开发者ID:pili-engineering,项目名称:PLDroidShortVideo,代码行数:8,代码来源:EyeAndThinView.java

示例5: updateView

import android.widget.SeekBar; //导入方法依赖的package包/类
private void updateView() {
    mSwitchBeautySecond.setImageResource(isOpen ? R.drawable.kai : R.drawable.guan);
    for (SeekBarRow row : seekBarRowList) {
        SeekBar seekBar = row.seekBar;
        seekBar.setEnabled(isOpen);
    }
}
 
开发者ID:pili-engineering,项目名称:PLDroidShortVideo,代码行数:8,代码来源:FaceBeautyView.java

示例6: onBindView

import android.widget.SeekBar; //导入方法依赖的package包/类
@Override
protected void onBindView(View view) {
    super.onBindView(view);
    SeekBar seekBar = (SeekBar) view.findViewById(R.id.seekbar);
    seekBar.setOnSeekBarChangeListener(this);
    seekBar.setMax(prefValueToSeekBarProgress(mMax));
    seekBar.setProgress(prefValueToSeekBarProgress(mValue));
    seekBar.setEnabled(isEnabled());
    mSummaryView = (TextView) view.findViewById(R.id.seekbar_amount);
    mSummaryView.setText(mSummary);
}
 
开发者ID:rkshuai,项目名称:chromium-for-android-56-debug-video,代码行数:12,代码来源:SeekBarPreference.java

示例7: onCheckedChanged

import android.widget.SeekBar; //导入方法依赖的package包/类
public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
	mChecked = isChecked;
	
	// update flag immediately
	setUseRingerVolume(mChecked);
	
	SeekBar seek = mNotificationHolder.seek;
	if (isChecked) {
		seek.setEnabled(false);
		seek.setProgress(mRingerHolder.seek.getProgress());
		mNotificationHolder.text.setText(mRingerHolder.text.getText());
	} else {
		seek.setEnabled(true);
	}
}
 
开发者ID:sdrausty,项目名称:buildAPKsApps,代码行数:16,代码来源:VolumeDialog.java

示例8: onBindView

import android.widget.SeekBar; //导入方法依赖的package包/类
@Override
protected void onBindView(View view) {
    Log.i(TAG, "SeekbarPreference----onBindView");
    super.onBindView(view);

    progress = getPersistedInt(60);
    seekBar = (SeekBar) view.findViewById(R.id.id_seekbar_threshold);
    textView = (TextView) view.findViewById(R.id.id_tv_threshold_value);

    seekBar.setMax(maxValue);
    seekBar.setProgress(progress);
    seekBar.setEnabled(isEnabled());
    seekBar.setOnSeekBarChangeListener(this);
    textView.setText(getSummary());
}
 
开发者ID:lazyparser,项目名称:xbot_head,代码行数:16,代码来源:SeekbarPreference.java

示例9: SeekbarPreference

import android.widget.SeekBar; //导入方法依赖的package包/类
public SeekbarPreference(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
    super(context, attrs, defStyleAttr, defStyleRes);
    seekBar = new SeekBar(context,attrs);
    seekBar.setEnabled(true);
    setLayoutResource(R.layout.preference_seekbar);
}
 
开发者ID:lazyparser,项目名称:xbot_head,代码行数:7,代码来源:SeekbarPreference.java


注:本文中的android.widget.SeekBar.setEnabled方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。