1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
public
class
MyWebView
extends
WebView {
public
MyWebView(Context context) {
super
(context);
}
public
MyWebView(Context context, AttributeSet attrs,
int
defStyle) {
super
(context, attrs, defStyle);
}
public
MyWebView(Context context, AttributeSet attrs) {
super
(context, attrs);
}
protected
void
onMeasure(
int
widthMeasureSpec,
int
heightMeasureSpec) {
int
expandSpec = MeasureSpec.makeMeasureSpec(Integer.MAX_VALUE >>
2
,
MeasureSpec.AT_MOST);
super
.onMeasure(widthMeasureSpec, expandSpec);
}
}
|