[Java] Android软键盘的隐藏显示、事件监听 →→→→→进入此内容的聊天室

来自 , 2019-06-19, 写在 Java, 查看 138 次.
URL http://www.code666.cn/view/c12d1f7c
  1.  
  2.  public class ResizeLayout extends LinearLayout{  
  3.        private static int count = 0;  
  4.          
  5.        public ResizeLayout(Context context, AttributeSet attrs) {  
  6.            super(context, attrs);  
  7.        }  
  8.          
  9.        @Override  
  10.        protected void onSizeChanged(int w, int h, int oldw, int oldh) {      
  11.          super.onSizeChanged(w, h, oldw, oldh);  
  12.              
  13.           Log.e("onSizeChanged " + count++, "=>onResize called! w="+w + ",h="+h+",oldw="+oldw+",oldh="+oldh);  
  14.       }  
  15.          
  16.       @Override  
  17.       protected void onLayout(boolean changed, int l, int t, int r, int b) {  
  18.           super.onLayout(changed, l, t, r, b);  
  19.           Log.e("onLayout " + count++, "=>OnLayout called! l=" + l + ", t=" + t + ",r=" + r + ",b="+b);  
  20.       }  
  21.          
  22.       @Override  
  23.       protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {  
  24.           super.onMeasure(widthMeasureSpec, heightMeasureSpec);  
  25.              
  26.           Log.e("onMeasure " + count++, "=>onMeasure called! widthMeasureSpec=" + widthMeasureSpec + ", heightMeasureSpec=" + heightMeasureSpec);  
  27.       }  
  28.  
  29.  
  30. //java/5562

回复 "Android软键盘的隐藏显示、事件监听"

这儿你可以回复上面这条便签

captcha