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
api-impl: misc additions for Oeffi
This commit is contained in:
@@ -59,4 +59,12 @@ public interface MenuItem {
|
||||
public MenuItem setAlphabeticShortcut(char alphaChar);
|
||||
|
||||
public MenuItem setShortcut(char numeric, char alpha);
|
||||
|
||||
public int getOrder();
|
||||
|
||||
public boolean isEnabled();
|
||||
|
||||
public CharSequence getTitleCondensed();
|
||||
|
||||
public CharSequence getTitle();
|
||||
}
|
||||
|
||||
@@ -942,6 +942,11 @@ public class View implements Drawable.Callback {
|
||||
}
|
||||
|
||||
native_setPadding(widget, paddingLeft, paddingTop, paddingRight, paddingBottom);
|
||||
|
||||
if (a.hasValue(com.android.internal.R.styleable.View_tag)) {
|
||||
tag = a.getText(com.android.internal.R.styleable.View_tag);
|
||||
}
|
||||
a.recycle();
|
||||
}
|
||||
onCreateDrawableState(0);
|
||||
}
|
||||
@@ -1436,7 +1441,7 @@ public class View implements Drawable.Callback {
|
||||
|
||||
public void requestLayout() {
|
||||
layoutRequested = true;
|
||||
if (parent != null) {
|
||||
if (parent != null && !parent.isLayoutRequested()) {
|
||||
parent.requestLayout();
|
||||
}
|
||||
native_requestLayout(widget);
|
||||
@@ -1949,4 +1954,6 @@ public class View implements Drawable.Callback {
|
||||
public void setImportantForAutofill(int flag) {}
|
||||
|
||||
public void setDefaultFocusHighlightEnabled(boolean enabled) {}
|
||||
|
||||
public void setHorizontalFadingEdgeEnabled(boolean horizontalFadingEdgeEnabled) {}
|
||||
}
|
||||
|
||||
@@ -12,6 +12,7 @@ import java.util.Objects;
|
||||
public class ViewGroup extends View implements ViewParent, ViewManager {
|
||||
public ArrayList<View> children;
|
||||
private OnHierarchyChangeListener onHierarchyChangeListener;
|
||||
private LayoutTransition transition;
|
||||
|
||||
public ViewGroup(Context context) {
|
||||
this(context, null);
|
||||
@@ -191,7 +192,9 @@ public class ViewGroup extends View implements ViewParent, ViewManager {
|
||||
return true;
|
||||
}
|
||||
|
||||
public LayoutTransition getLayoutTransition() { return null; }
|
||||
public LayoutTransition getLayoutTransition() {
|
||||
return transition;
|
||||
}
|
||||
|
||||
public static int getChildMeasureSpec(int spec, int padding, int childDimension) {
|
||||
int specMode = MeasureSpec.getMode(spec);
|
||||
@@ -378,6 +381,10 @@ public class ViewGroup extends View implements ViewParent, ViewManager {
|
||||
return null;
|
||||
}
|
||||
|
||||
public void setLayoutTransition(LayoutTransition transition) {
|
||||
this.transition = transition;
|
||||
}
|
||||
|
||||
public static class LayoutParams {
|
||||
public static final int FILL_PARENT = -1;
|
||||
public static final int MATCH_PARENT = -1;
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
package android.view.animation;
|
||||
|
||||
import android.os.Handler;
|
||||
import android.os.Looper;
|
||||
|
||||
public class Animation {
|
||||
|
||||
public interface AnimationListener {
|
||||
@@ -20,8 +23,15 @@ public class Animation {
|
||||
public void setStartOffset(long offset) {}
|
||||
|
||||
public void setAnimationListener(AnimationListener l) {
|
||||
l.onAnimationEnd(this); // FIXME
|
||||
new Handler(Looper.getMainLooper()).post(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
l.onAnimationEnd(Animation.this); // FIXME
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public void setRepeatCount(int count) {}
|
||||
|
||||
public void reset() {}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user