• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright 2018 The Android Open Source Project
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  *      http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
17 package com.android.widget;
18 
19 import android.media.update.ViewGroupProvider;
20 import android.util.AttributeSet;
21 import android.view.MotionEvent;
22 import android.view.View;
23 import android.view.ViewGroup;
24 
25 public abstract class ViewGroupImpl implements ViewGroupProvider {
26     private final ViewGroupProvider mSuperProvider;
27 
ViewGroupImpl(ViewGroup instance, ViewGroupProvider superProvider, ViewGroupProvider privateProvider)28     public ViewGroupImpl(ViewGroup instance,
29             ViewGroupProvider superProvider, ViewGroupProvider privateProvider) {
30         mSuperProvider = superProvider;
31     }
32 
33     @Override
onAttachedToWindow_impl()34     public void onAttachedToWindow_impl() {
35         mSuperProvider.onAttachedToWindow_impl();
36     }
37 
38     @Override
onDetachedFromWindow_impl()39     public void onDetachedFromWindow_impl() {
40         mSuperProvider.onDetachedFromWindow_impl();
41     }
42 
43     @Override
getAccessibilityClassName_impl()44     public CharSequence getAccessibilityClassName_impl() {
45         return mSuperProvider.getAccessibilityClassName_impl();
46     }
47 
48     @Override
onTouchEvent_impl(MotionEvent ev)49     public boolean onTouchEvent_impl(MotionEvent ev) {
50         return mSuperProvider.onTouchEvent_impl(ev);
51     }
52 
53     @Override
onTrackballEvent_impl(MotionEvent ev)54     public boolean onTrackballEvent_impl(MotionEvent ev) {
55         return mSuperProvider.onTrackballEvent_impl(ev);
56     }
57 
58     @Override
onFinishInflate_impl()59     public void onFinishInflate_impl() {
60         mSuperProvider.onFinishInflate_impl();
61     }
62 
63     @Override
setEnabled_impl(boolean enabled)64     public void setEnabled_impl(boolean enabled) {
65         mSuperProvider.setEnabled_impl(enabled);
66     }
67 
68     @Override
onVisibilityAggregated_impl(boolean isVisible)69     public void onVisibilityAggregated_impl(boolean isVisible) {
70         mSuperProvider.onVisibilityAggregated_impl(isVisible);
71     }
72 
73     @Override
onLayout_impl(boolean changed, int left, int top, int right, int bottom)74     public void onLayout_impl(boolean changed, int left, int top, int right, int bottom) {
75         mSuperProvider.onLayout_impl(changed, left, top, right, bottom);
76     }
77 
78     @Override
onMeasure_impl(int widthMeasureSpec, int heightMeasureSpec)79     public void onMeasure_impl(int widthMeasureSpec, int heightMeasureSpec) {
80         mSuperProvider.onMeasure_impl(widthMeasureSpec, heightMeasureSpec);
81     }
82 
83     @Override
getSuggestedMinimumWidth_impl()84     public int getSuggestedMinimumWidth_impl() {
85         return mSuperProvider.getSuggestedMinimumWidth_impl();
86     }
87 
88     @Override
getSuggestedMinimumHeight_impl()89     public int getSuggestedMinimumHeight_impl() {
90         return mSuperProvider.getSuggestedMinimumHeight_impl();
91     }
92 
93     @Override
setMeasuredDimension_impl(int measuredWidth, int measuredHeight)94     public void setMeasuredDimension_impl(int measuredWidth, int measuredHeight) {
95         mSuperProvider.setMeasuredDimension_impl(measuredWidth, measuredHeight);
96     }
97 
98     @Override
dispatchTouchEvent_impl(MotionEvent ev)99     public boolean dispatchTouchEvent_impl(MotionEvent ev) {
100         return mSuperProvider.dispatchTouchEvent_impl(ev);
101     }
102 
103     @Override
checkLayoutParams_impl(ViewGroup.LayoutParams p)104     public boolean checkLayoutParams_impl(ViewGroup.LayoutParams p) {
105         return mSuperProvider.checkLayoutParams_impl(p);
106     }
107 
108     @Override
generateDefaultLayoutParams_impl()109     public ViewGroup.LayoutParams generateDefaultLayoutParams_impl() {
110         return mSuperProvider.generateDefaultLayoutParams_impl();
111     }
112 
113     @Override
generateLayoutParams_impl(AttributeSet attrs)114     public ViewGroup.LayoutParams generateLayoutParams_impl(AttributeSet attrs) {
115         return mSuperProvider.generateLayoutParams_impl(attrs);
116     }
117 
118     @Override
generateLayoutParams_impl(ViewGroup.LayoutParams lp)119     public ViewGroup.LayoutParams generateLayoutParams_impl(ViewGroup.LayoutParams lp) {
120         return mSuperProvider.generateLayoutParams_impl(lp);
121     }
122 
123     @Override
shouldDelayChildPressedState_impl()124     public boolean shouldDelayChildPressedState_impl() {
125         return mSuperProvider.shouldDelayChildPressedState_impl();
126     }
127 
128     @Override
measureChildWithMargins_impl(View child, int parentWidthMeasureSpec, int widthUsed, int parentHeightMeasureSpec, int heightUsed)129     public void measureChildWithMargins_impl(View child,
130         int parentWidthMeasureSpec, int widthUsed, int parentHeightMeasureSpec, int heightUsed) {
131         mSuperProvider.measureChildWithMargins_impl(child,
132                 parentWidthMeasureSpec, widthUsed, parentHeightMeasureSpec, heightUsed);
133     }
134 }
135