mirror of https://github.com/M66B/FairEmail.git
Refactoring
This commit is contained in:
parent
328a864f95
commit
28c550f90f
|
@ -49,7 +49,6 @@ public class WebViewEx extends WebView implements DownloadListener, View.OnLongC
|
||||||
private int height;
|
private int height;
|
||||||
private IWebView intf;
|
private IWebView intf;
|
||||||
private Runnable onPageLoaded;
|
private Runnable onPageLoaded;
|
||||||
|
|
||||||
private static String userAgent = null;
|
private static String userAgent = null;
|
||||||
|
|
||||||
private static final long PAGE_LOADED_FALLBACK_DELAY = 1500L; // milliseconds
|
private static final long PAGE_LOADED_FALLBACK_DELAY = 1500L; // milliseconds
|
||||||
|
@ -210,8 +209,10 @@ public class WebViewEx extends WebView implements DownloadListener, View.OnLongC
|
||||||
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
|
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
|
||||||
if (height > getMinimumHeight())
|
if (height > getMinimumHeight())
|
||||||
super.onMeasure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(height, MeasureSpec.AT_MOST));
|
super.onMeasure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(height, MeasureSpec.AT_MOST));
|
||||||
else
|
else {
|
||||||
super.onMeasure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(getResources().getDisplayMetrics().heightPixels, MeasureSpec.AT_MOST));
|
int max = getResources().getDisplayMetrics().heightPixels;
|
||||||
|
super.onMeasure(widthMeasureSpec, MeasureSpec.makeMeasureSpec(max, MeasureSpec.AT_MOST));
|
||||||
|
}
|
||||||
|
|
||||||
int mh = getMeasuredHeight();
|
int mh = getMeasuredHeight();
|
||||||
Log.i("Measured height=" + mh + " last=" + height);
|
Log.i("Measured height=" + mh + " last=" + height);
|
||||||
|
|
Loading…
Reference in New Issue