android.widget.ImageButton.onSaveInstanceState()方法的使用及代码示例

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

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

ImageButton.onSaveInstanceState介绍

暂无

代码示例

代码示例来源:origin: Clans/FloatingActionButton

@Override
public Parcelable onSaveInstanceState() {
  Parcelable superState = super.onSaveInstanceState();
  ProgressSavedState ss = new ProgressSavedState(superState);
  ss.mCurrentProgress = this.mCurrentProgress;
  ss.mTargetProgress = this.mTargetProgress;
  ss.mSpinSpeed = this.mSpinSpeed;
  ss.mProgressWidth = this.mProgressWidth;
  ss.mProgressColor = this.mProgressColor;
  ss.mProgressBackgroundColor = this.mProgressBackgroundColor;
  ss.mShouldProgressIndeterminate = this.mProgressIndeterminate;
  ss.mShouldSetProgress = this.mProgressBarEnabled && mProgress > 0 && !this.mProgressIndeterminate;
  ss.mProgress = this.mProgress;
  ss.mAnimateProgress = this.mAnimateProgress;
  ss.mShowProgressBackground = this.mShowProgressBackground;
  return ss;
}

代码示例来源:origin: koral--/android-gif-drawable

@Override
public Parcelable onSaveInstanceState() {
  Drawable source = mFreezesAnimation ? getDrawable() : null;
  Drawable background = mFreezesAnimation ? getBackground() : null;
  return new GifViewSavedState(super.onSaveInstanceState(), source, background);
}

代码示例来源:origin: Blankeer/MDWechat

@Override
public Parcelable onSaveInstanceState() {
  Parcelable superState = super.onSaveInstanceState();
  ProgressSavedState ss = new ProgressSavedState(superState);
  ss.mCurrentProgress = this.mCurrentProgress;
  ss.mTargetProgress = this.mTargetProgress;
  ss.mSpinSpeed = this.mSpinSpeed;
  ss.mProgressWidth = this.mProgressWidth;
  ss.mProgressColor = this.mProgressColor;
  ss.mProgressBackgroundColor = this.mProgressBackgroundColor;
  ss.mShouldProgressIndeterminate = this.mProgressIndeterminate;
  ss.mShouldSetProgress = this.mProgressBarEnabled && mProgress > 0 && !this.mProgressIndeterminate;
  ss.mProgress = this.mProgress;
  ss.mAnimateProgress = this.mAnimateProgress;
  ss.mShowProgressBackground = this.mShowProgressBackground;
  return ss;
}

代码示例来源:origin: douzifly/clear-todolist

@Override
public Parcelable onSaveInstanceState() {
  Parcelable superState = super.onSaveInstanceState();
  ProgressSavedState ss = new ProgressSavedState(superState);
  ss.mCurrentProgress = this.mCurrentProgress;
  ss.mTargetProgress = this.mTargetProgress;
  ss.mSpinSpeed = this.mSpinSpeed;
  ss.mProgressWidth = this.mProgressWidth;
  ss.mProgressColor = this.mProgressColor;
  ss.mProgressBackgroundColor = this.mProgressBackgroundColor;
  ss.mShouldProgressIndeterminate = this.mProgressIndeterminate;
  ss.mShouldSetProgress = this.mProgressBarEnabled && mProgress > 0 && !this.mProgressIndeterminate;
  ss.mProgress = this.mProgress;
  ss.mAnimateProgress = this.mAnimateProgress;
  ss.mShowProgressBackground = this.mShowProgressBackground;
  return ss;
}

代码示例来源:origin: konradrenner/kolabnotes-android

@Override
public Parcelable onSaveInstanceState() {
  Parcelable superState = super.onSaveInstanceState();
  SavedState savedState = new SavedState(superState);
  savedState.checked = isChecked();
  return savedState;
}

代码示例来源:origin: LongDinhF/Hamburger-Button

@Override
public Parcelable onSaveInstanceState() {
  Parcelable superState = super.onSaveInstanceState();
  HBButtonSavedState hbButtonSavedState = new HBButtonSavedState(superState);
  hbButtonSavedState.borderThickness = getBorderThickness();
  hbButtonSavedState.borderColor = getBorderColor();
  hbButtonSavedState.borderCornersRadius = getBorderCornersRadius();
  hbButtonSavedState.backgroundColor = getBackgroundColor();
  hbButtonSavedState.lineThickness = getLineThickness();
  hbButtonSavedState.lineColor = getLineColor();
  hbButtonSavedState.lineCornersRadius = getLineCornersRadius();
  hbButtonSavedState.animationDuration = getAnimationDuration();
  hbButtonSavedState.lineWidthPadding = getLineWidthPadding();
  hbButtonSavedState.slideLeftToRight = isSlideLeftToRight();
  hbButtonSavedState.currentState = getCurrentState();
  hbButtonSavedState.rfBorder = mRFBorder;
  hbButtonSavedState.rfBackground = mRFBackground;
  hbButtonSavedState.rfSlider = mRFSlider;
  hbButtonSavedState.lineCenter = mLineCenter;
  hbButtonSavedState.lineTop = mLineTop;
  hbButtonSavedState.lineBottom = mLineBottom;
  return hbButtonSavedState;
}

相关文章

ImageButton类方法