You've already forked android_translation_layer
mirror of
https://gitlab.com/android_translation_layer/android_translation_layer.git
synced 2025-10-27 11:48:10 -07:00
remove View.haveComplexMeasure as it is redundant with haveCustomMeasure
Makes haveCustomMeasure true by default. And disable it for widgets which previously set haveComplexMeasure
This commit is contained in:
@@ -27,7 +27,7 @@ public class ImageView extends View {
|
||||
public ImageView(Context context, AttributeSet attrs, int defStyleAttr) {
|
||||
super(context, attrs, defStyleAttr);
|
||||
|
||||
haveComplexMeasure = true;
|
||||
haveCustomMeasure = false;
|
||||
if (attrs != null) {
|
||||
int resid = attrs.getAttributeResourceValue("http://schemas.android.com/apk/res/android", "src", 0);
|
||||
if (resid != 0 && !getResources().getString(resid).endsWith(".xml")) {
|
||||
|
||||
@@ -14,7 +14,7 @@ public class ProgressBar extends View {
|
||||
|
||||
public ProgressBar(Context context, AttributeSet attrs, int defStyle) {
|
||||
super(context, attrs, defStyle);
|
||||
haveComplexMeasure = true;
|
||||
haveCustomMeasure = false;
|
||||
TypedArray a = context.obtainStyledAttributes(attrs, com.android.internal.R.styleable.ProgressBar, defStyle, 0);
|
||||
setIndeterminate(a.getBoolean(com.android.internal.R.styleable.ProgressBar_indeterminate, false));
|
||||
a.recycle();
|
||||
|
||||
@@ -8,12 +8,12 @@ public class Space extends View {
|
||||
|
||||
public Space(Context context) {
|
||||
super(context);
|
||||
haveComplexMeasure = true;
|
||||
haveCustomMeasure = false;
|
||||
}
|
||||
|
||||
public Space(Context context, AttributeSet attributeSet) {
|
||||
super(context, attributeSet);
|
||||
haveComplexMeasure = true;
|
||||
haveCustomMeasure = false;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -60,7 +60,7 @@ public class TextView extends View {
|
||||
}
|
||||
} catch(java.lang.Exception e) { System.out.println("exception while inflating TextView:"); e.printStackTrace(); }
|
||||
a.recycle();
|
||||
haveComplexMeasure = true;
|
||||
haveCustomMeasure = false;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user