android.widget.SeekBar.setVisibility()方法的使用及代码示例

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

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

SeekBar.setVisibility介绍

暂无

代码示例

代码示例来源:origin: jiajunhui/PlayerBase

private void setBottomSeekBarState(boolean state){
  mBottomSeekBar.setVisibility(state?View.VISIBLE:View.GONE);
}

代码示例来源:origin: Rukey7/MvpApp

/**
 * 切换弹幕相关控件View的显示/隐藏
 *
 * @param isShow 是否显示
 */
private void _toggleDanmakuView(boolean isShow) {
  if (mIsEnableDanmaku) {
    if (isShow) {
      mIvDanmakuControl.setVisibility(VISIBLE);
      mTvOpenEditDanmaku.setVisibility(VISIBLE);
      mTvTimeSeparator.setVisibility(VISIBLE);
      mDanmakuPlayerSeek.setVisibility(VISIBLE);
      mPlayerSeek.setVisibility(GONE);
    } else {
      mIvDanmakuControl.setVisibility(GONE);
      mTvOpenEditDanmaku.setVisibility(GONE);
      mTvTimeSeparator.setVisibility(GONE);
      mDanmakuPlayerSeek.setVisibility(GONE);
      mPlayerSeek.setVisibility(VISIBLE);
    }
  }
}

代码示例来源:origin: Rukey7/MvpApp

/**
   * 隐藏除视频外所有视图
   */
  private void _hideAllView(boolean isTouchLock) {
//        mPlayerThumb.setVisibility(View.GONE);
    mFlTouchLayout.setVisibility(View.GONE);
    mFullscreenTopBar.setVisibility(View.GONE);
    mWindowTopBar.setVisibility(View.GONE);
    mLlBottomBar.setVisibility(View.GONE);
    _showAspectRatioOptions(false);
    if (!isTouchLock) {
      mIvPlayerLock.setVisibility(View.GONE);
      mIsShowBar = false;
    }
    if (mIsEnableDanmaku) {
      mDanmakuPlayerSeek.setVisibility(GONE);
    }
    if (mIsNeedRecoverScreen) {
      mTvRecoverScreen.setVisibility(GONE);
    }
  }

代码示例来源:origin: CarGuo/GSYVideoPlayer

/**
 * 根据是否广告url修改ui显示状态
 */
protected void changeAdUIState() {
  if (mJumpAd != null) {
    mJumpAd.setVisibility((isFirstPrepared) ? VISIBLE : GONE);
  }
  if (mADTime != null) {
    mADTime.setVisibility((isFirstPrepared) ? VISIBLE : GONE);
  }
  if (mBottomContainer != null) {
    int color = (isFirstPrepared) ? Color.TRANSPARENT : getContext().getResources().getColor(R.color.bottom_container_bg);
    mBottomContainer.setBackgroundColor(color);
  }
  if (mCurrentTimeTextView != null) {
    mCurrentTimeTextView.setVisibility((isFirstPrepared) ? INVISIBLE : VISIBLE);
  }
  if (mTotalTimeTextView != null) {
    mTotalTimeTextView.setVisibility((isFirstPrepared) ? INVISIBLE : VISIBLE);
  }
  if (mProgressBar != null) {
    mProgressBar.setVisibility((isFirstPrepared) ? INVISIBLE : VISIBLE);
    mProgressBar.setEnabled(!(isFirstPrepared));
  }
}

代码示例来源:origin: CarGuo/GSYVideoPlayer

/**
 * 小窗口
 **/
@Override
protected void setSmallVideoTextureView() {
  if (mProgressBar != null) {
    mProgressBar.setOnTouchListener(null);
    mProgressBar.setVisibility(INVISIBLE);
  }
  if (mFullscreenButton != null) {
    mFullscreenButton.setOnTouchListener(null);
    mFullscreenButton.setVisibility(INVISIBLE);
  }
  if (mCurrentTimeTextView != null) {
    mCurrentTimeTextView.setVisibility(INVISIBLE);
  }
  if (mTextureViewContainer != null) {
    mTextureViewContainer.setOnClickListener(null);
  }
  if (mSmallClose != null) {
    mSmallClose.setVisibility(VISIBLE);
    mSmallClose.setOnClickListener(new OnClickListener() {
      @Override
      public void onClick(View v) {
        hideSmallVideo();
        releaseVideos();
      }
    });
  }
}

代码示例来源:origin: CarGuo/GSYVideoPlayer

/**
 * 根据是否广告url修改ui显示状态
 */
protected void changeAdUIState() {
  if (mJumpAd != null) {
    mJumpAd.setVisibility((isFirstPrepared && isAdModel) ? VISIBLE : GONE);
  }
  if (mADTime != null) {
    mADTime.setVisibility((isFirstPrepared && isAdModel) ? VISIBLE : GONE);
  }
  if (mWidgetContainer != null) {
    mWidgetContainer.setVisibility((isFirstPrepared && isAdModel) ? GONE : VISIBLE);
  }
  if (mBottomContainer != null) {
    int color = (isFirstPrepared && isAdModel) ? Color.TRANSPARENT : getContext().getResources().getColor(R.color.bottom_container_bg);
    mBottomContainer.setBackgroundColor(color);
  }
  if (mCurrentTimeTextView != null) {
    mCurrentTimeTextView.setVisibility((isFirstPrepared && isAdModel) ? INVISIBLE : VISIBLE);
  }
  if (mTotalTimeTextView != null) {
    mTotalTimeTextView.setVisibility((isFirstPrepared && isAdModel) ? INVISIBLE : VISIBLE);
  }
  if (mProgressBar != null) {
    mProgressBar.setVisibility((isFirstPrepared && isAdModel) ? INVISIBLE : VISIBLE);
    mProgressBar.setEnabled(!(isFirstPrepared && isAdModel));
  }
}

代码示例来源:origin: Rukey7/MvpApp

mIvPlayerLock.setVisibility(isShowBar ? View.VISIBLE : View.GONE);
if (mIsEnableDanmaku) {
  mDanmakuPlayerSeek.setVisibility(isShowBar ? View.VISIBLE : View.GONE);
mIvPlayerLock.setVisibility(View.GONE);
if (mIsEnableDanmaku) {
  mDanmakuPlayerSeek.setVisibility(GONE);

代码示例来源:origin: Rukey7/MvpApp

/**
 * 切换控制锁
 */
private void _togglePlayerLock() {
  mIsForbidTouch = !mIsForbidTouch;
  mIvPlayerLock.setSelected(mIsForbidTouch);
  if (mIsForbidTouch) {
    mOrientationListener.disable();
    _hideAllView(true);
  } else {
    if (!mIsForbidOrientation) {
      mOrientationListener.enable();
    }
    mFullscreenTopBar.setVisibility(View.VISIBLE);
    mLlBottomBar.setVisibility(View.VISIBLE);
    if (mIsEnableDanmaku) {
      mDanmakuPlayerSeek.setVisibility(VISIBLE);
    }
    if (mIsNeedRecoverScreen) {
      mTvRecoverScreen.setVisibility(VISIBLE);
    }
  }
}

代码示例来源:origin: pili-engineering/PLDroidShortVideo

public void onClickBrightness(View v) {
  boolean isVisible = mAdjustBrightnessSeekBar.getVisibility() == View.VISIBLE;
  mAdjustBrightnessSeekBar.setVisibility(isVisible ? View.GONE : View.VISIBLE);
}

代码示例来源:origin: pili-engineering/PLDroidShortVideo

public void onClickBrightness(View v) {
  boolean isVisible = mAdjustBrightnessSeekBar.getVisibility() == View.VISIBLE;
  mAdjustBrightnessSeekBar.setVisibility(isVisible ? View.GONE : View.VISIBLE);
}

代码示例来源:origin: stackoverflow.com

seekBar.setThumb(thumb);
seekBar.setProgress(1);
seekBar.setVisibility(View.VISIBLE);
seekBar.setBackgroundColor(Color.BLUE);

代码示例来源:origin: 18Gray/ProCamera

@Override
  public void onClick(View v)
  {
    seekBarSaturation.setVisibility(View.VISIBLE);
    seekBarDuibidu.setVisibility(View.GONE);
    seekBarLight.setVisibility(View.GONE);
    updateTextView(textViewList, 0, context);
  }
});

代码示例来源:origin: 18Gray/ProCamera

@Override
  public void onClick(View v)
  {
    seekBarSaturation.setVisibility(View.GONE);
    seekBarDuibidu.setVisibility(View.GONE);
    seekBarLight.setVisibility(View.VISIBLE);
    updateTextView(textViewList, 2, context);
  }
});

代码示例来源:origin: renyuneyun/Easer

@Override
  public void onCheckedChanged(CompoundButton compoundButton, boolean b) {
    seekBar_ring.setVisibility(b ? View.VISIBLE : View.GONE);
  }
});

代码示例来源:origin: zxfnicholas/CameraSDK

@Override
  public void onClick(View v) {
    initEraser();
    brush_layout.setVisibility(View.GONE);
    seekbar_eraser.setVisibility(View.VISIBLE);
  }
});

代码示例来源:origin: zxfnicholas/CameraSDK

@Override
  public void onClick(View v) {
    initBrush();
    brush_layout.setVisibility(View.VISIBLE);
    seekbar_eraser.setVisibility(View.GONE);
  }
});

代码示例来源:origin: Swati4star/Images-to-PDF

/**
 * Shows the brush effect
 */
private void showBrushEffect() {
  mPhotoEditor.setBrushDrawingMode(true);
  doodleSeekBar.setVisibility(View.VISIBLE);
  brushColorsView.setVisibility(View.VISIBLE);
  mDoodleSelected = true;
}

代码示例来源:origin: Swati4star/Images-to-PDF

/**
 * Hides brush effect
 */
private void hideBrushEffect() {
  mPhotoEditor.setBrushDrawingMode(false);
  doodleSeekBar.setVisibility(View.GONE);
  brushColorsView.setVisibility(View.GONE);
}

代码示例来源:origin: com.albedinsky.android/ui

/**
 */
@Override
public void setVisibility(int visibility) {
  super.setVisibility(visibility);
  if (mDiscreteIndicator != null) mDiscreteIndicator.setVisible(visibility == VISIBLE, false);
}

代码示例来源:origin: IhorKlimov/Android-WebRtc

@Override
public void onStart() {
  super.onStart();
  Bundle args = getIntent().getExtras();
  if (args != null) {
    String contactName = args.getString(EXTRA_ROOMID);
    binding.contactNameCall.setText(contactName);
  }
  binding.captureFormatTextCall.setVisibility(View.GONE);
  binding.captureFormatSliderCall.setVisibility(View.GONE);
}

相关文章

SeekBar类方法