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
findViewById(): only search among child views
also set default content view in Window
This commit is contained in:
@@ -304,6 +304,17 @@ public class ViewGroup extends View implements ViewParent, ViewManager {
|
||||
|
||||
public void setClipToPadding(boolean clipToPadding) {}
|
||||
|
||||
public View findViewById(int id) {
|
||||
if (this.id == id)
|
||||
return this;
|
||||
for (View child: children) {
|
||||
View result = child.findViewById(id);
|
||||
if (result != null)
|
||||
return result;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public static class LayoutParams {
|
||||
public static final int FILL_PARENT = -1;
|
||||
public static final int MATCH_PARENT = -1;
|
||||
|
||||
Reference in New Issue
Block a user