android.webkit.WebView.onSizeChanged()方法的使用及代码示例

x33g5p2x  于2022-02-02 转载在 其他  
字(1.5k)|赞(0)|评价(0)|浏览(156)

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

WebView.onSizeChanged介绍

暂无

代码示例

代码示例来源:origin: smuyyh/BookReader

@Override
protected void onSizeChanged(int w, int h, int ow, int oh) {
  super.onSizeChanged(w, h, ow, oh);
  if (mSizeChangedListener != null) {
    mSizeChangedListener.onSizeChanged(h);
  }
}

代码示例来源:origin: k9mail/k-9

private void performSizeChange(int ow, int oh) {
  super.onSizeChanged(mRealWidth, mRealHeight, ow, oh);
  mLastSizeChangeTime = mClock.getTime();
}

代码示例来源:origin: k9mail/k-9

@Override
protected void onSizeChanged(int w, int h, int ow, int oh) {
  if (NO_THROTTLE) {
    super.onSizeChanged(w, h, ow, oh);
    return;
  }
  mRealWidth = w;
  mRealHeight = h;
  long now = mClock.getTime();
  boolean recentlySized = (now - mLastSizeChangeTime < MIN_RESIZE_INTERVAL);
  // It's known that the previous resize event may cause a resize event immediately. If
  // this happens sufficiently close to the last resize event, drop it on the floor.
  if (mIgnoreNext) {
    mIgnoreNext = false;
    if (recentlySized) {
      Timber.w("Supressing size change in RigidWebView");
      return;
    }
  }
  if (recentlySized) {
    mThrottle.onEvent();
  } else {
    // It's been a sufficiently long time - just perform the resize as normal. This should
    // be the normal code path.
    performSizeChange(ow, oh);
  }
}

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

/**
 */
@Override
protected void onSizeChanged(int w, int h, int oldw, int oldh) {
  super.onSizeChanged(w, h, oldw, oldh);
  this.ensureDecorator();
  mDecorator.onSizeChanged(w, h, oldw, oldh);
}

相关文章

WebView类方法