本文整理了Java中android.widget.SeekBar.setOnSeekBarChangeListener()
方法的一些代码示例,展示了SeekBar.setOnSeekBarChangeListener()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。SeekBar.setOnSeekBarChangeListener()
方法的具体详情如下:
包路径:android.widget.SeekBar
类名称:SeekBar
方法名:setOnSeekBarChangeListener
暂无
代码示例来源:origin: smuyyh/BookReader
public void setOnSeekBarChangeListener(OnSeekBarChangeListener l) {
mOnSeekBarChangeListener = l;
super.setOnSeekBarChangeListener(mOnSeekBarChangeListener);
}
代码示例来源:origin: TeamNewPipe/NewPipe
private void buildSeekBar() {
progressCurrentTime = rootView.findViewById(R.id.current_time);
progressSeekBar = rootView.findViewById(R.id.seek_bar);
progressEndTime = rootView.findViewById(R.id.end_time);
progressLiveSync = rootView.findViewById(R.id.live_sync);
seekDisplay = rootView.findViewById(R.id.seek_display);
progressSeekBar.setOnSeekBarChangeListener(this);
progressLiveSync.setOnClickListener(this);
}
代码示例来源:origin: TeamNewPipe/NewPipe
@Override
public void initListeners() {
super.initListeners();
playbackSeekBar.setOnSeekBarChangeListener(this);
playbackSpeedTextView.setOnClickListener(this);
qualityTextView.setOnClickListener(this);
captionTextView.setOnClickListener(this);
resizeView.setOnClickListener(this);
playbackLiveSync.setOnClickListener(this);
}
代码示例来源:origin: commonsguy/cw-omnibus
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
thingToResize=findViewById(R.id.resize);
horizontal=(SeekBar)findViewById(R.id.horizontal);
vertical=(SeekBar)findViewById(R.id.vertical);
horizontal.setMax(144); // 240 less 96 starting size
vertical.setMax(144); // keep it square @ max
horizontal.setOnSeekBarChangeListener(h);
vertical.setOnSeekBarChangeListener(v);
}
代码示例来源:origin: robolectric/robolectric
@Implementation
protected void setOnSeekBarChangeListener(SeekBar.OnSeekBarChangeListener listener) {
this.listener = listener;
Shadow.directlyOn(realSeekBar, SeekBar.class).setOnSeekBarChangeListener(listener);
}
代码示例来源:origin: commonsguy/cw-omnibus
@Override
public View onCreateView(LayoutInflater inflater,
ViewGroup container,
Bundle savedInstanceState) {
setRetainInstance(true);
View result=inflater.inflate(R.layout.scaleclip, container, false);
SeekBar bar=((SeekBar)result.findViewById(R.id.level));
bar.setOnSeekBarChangeListener(this);
image=(ImageView)result.findViewById(R.id.image);
setImageBackground(image);
image.setImageLevel(bar.getProgress());
return(result);
}
代码示例来源:origin: seven332/EhViewer
@Override
protected void onBindView(View view) {
super.onBindView(view);
SeekBar seekBar = (SeekBar) view.findViewById(R.id.seekbar);
seekBar.setOnSeekBarChangeListener(this);
seekBar.setMax(mMax);
seekBar.setProgress(mProgress);
seekBar.setEnabled(isEnabled());
}
代码示例来源:origin: TeamNewPipe/NewPipe
private void setupPitchControl(@NonNull View rootView) {
pitchSlider = rootView.findViewById(R.id.pitchSeekbar);
TextView pitchMinimumText = rootView.findViewById(R.id.pitchMinimumText);
TextView pitchMaximumText = rootView.findViewById(R.id.pitchMaximumText);
pitchCurrentText = rootView.findViewById(R.id.pitchCurrentText);
pitchStepDownText = rootView.findViewById(R.id.pitchStepDown);
pitchStepUpText = rootView.findViewById(R.id.pitchStepUp);
if (pitchCurrentText != null)
pitchCurrentText.setText(PlayerHelper.formatPitch(pitch));
if (pitchMaximumText != null)
pitchMaximumText.setText(PlayerHelper.formatPitch(MAXIMUM_PLAYBACK_VALUE));
if (pitchMinimumText != null)
pitchMinimumText.setText(PlayerHelper.formatPitch(MINIMUM_PLAYBACK_VALUE));
if (pitchSlider != null) {
pitchSlider.setMax(strategy.progressOf(MAXIMUM_PLAYBACK_VALUE));
pitchSlider.setProgress(strategy.progressOf(pitch));
pitchSlider.setOnSeekBarChangeListener(getOnPitchChangedListener());
}
}
代码示例来源:origin: commonsguy/cw-omnibus
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
value=(TextView)findViewById(R.id.value);
SeekBar seekBar=(SeekBar)findViewById(R.id.seek_bar);
seekBar.setOnSeekBarChangeListener(this);
}
代码示例来源:origin: jiajunhui/PlayerBase
@Override
public void onReceiverBind() {
super.onReceiverBind();
unbinder = ButterKnife.bind(this, getView());
mSeekBar.setOnSeekBarChangeListener(onSeekBarChangeListener);
getGroupValue().registerOnGroupValueUpdateListener(mOnGroupValueUpdateListener);
}
代码示例来源:origin: robolectric/robolectric
@Test
public void testOnSeekBarChangedListener() {
assertThat(shadow.getOnSeekBarChangeListener()).isSameAs(listener);
seekBar.setOnSeekBarChangeListener(null);
assertThat(shadow.getOnSeekBarChangeListener()).isNull();
}
代码示例来源:origin: robolectric/robolectric
@Before
public void setup() {
seekBar = new SeekBar(ApplicationProvider.getApplicationContext());
shadow = Shadows.shadowOf(seekBar);
listener = new TestSeekBarChangedListener();
transcript = new ArrayList<>();
seekBar.setOnSeekBarChangeListener(listener);
}
代码示例来源:origin: PhilJay/MPAndroidChart
seekBarX.setOnSeekBarChangeListener(this);
seekBarY.setOnSeekBarChangeListener(this);
代码示例来源:origin: PhilJay/MPAndroidChart
seekBarX.setOnSeekBarChangeListener(this);
seekBarY.setOnSeekBarChangeListener(this);
代码示例来源:origin: PhilJay/MPAndroidChart
seekBarY.setOnSeekBarChangeListener(this);
seekBarX.setOnSeekBarChangeListener(this);
代码示例来源:origin: PhilJay/MPAndroidChart
seekBarX.setOnSeekBarChangeListener(this);
seekBarY.setOnSeekBarChangeListener(this);
代码示例来源:origin: PhilJay/MPAndroidChart
seekBarX.setOnSeekBarChangeListener(this);
seekBarY.setOnSeekBarChangeListener(this);
代码示例来源:origin: PhilJay/MPAndroidChart
seekBarX.setOnSeekBarChangeListener(this);
seekBarY.setOnSeekBarChangeListener(this);
代码示例来源:origin: PhilJay/MPAndroidChart
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
WindowManager.LayoutParams.FLAG_FULLSCREEN);
setContentView(R.layout.activity_performance_linechart);
setTitle("PerformanceLineChart");
tvCount = findViewById(R.id.tvValueCount);
seekBarValues = findViewById(R.id.seekbarValues);
seekBarValues.setOnSeekBarChangeListener(this);
chart = findViewById(R.id.chart1);
chart.setDrawGridBackground(false);
// no description text
chart.getDescription().setEnabled(false);
// enable touch gestures
chart.setTouchEnabled(true);
// enable scaling and dragging
chart.setDragEnabled(true);
chart.setScaleEnabled(true);
// if disabled, scaling can be done on x- and y-axis separately
chart.setPinchZoom(false);
chart.getAxisLeft().setDrawGridLines(false);
chart.getAxisRight().setEnabled(false);
chart.getXAxis().setDrawGridLines(true);
chart.getXAxis().setDrawAxisLine(false);
seekBarValues.setProgress(9000);
// don't forget to refresh the drawing
chart.invalidate();
}
代码示例来源:origin: PhilJay/MPAndroidChart
seekBarX.setOnSeekBarChangeListener(this);
seekBarY.setOnSeekBarChangeListener(this);
内容来源于网络,如有侵权,请联系作者删除!