获取键盘升起后的高度

//监听键盘事件代理

    NSNotificationCenter *center=[NSNotificationCenter defaultCenter];orm

    [center addObserver:self selector:@selector(keyboard:) name:UIKeyboardWillChangeFrameNotification object:nil];server

 

#pragma mark 代理方法事件

- (void)keyboard : (NSNotification *) noteInfo{io

    //获取键盘的高度form

    CGRect rect=[noteInfo.userInfo[UIKeyboardFrameEndUserInfoKey] CGRectValue];transform

   

    if (JWScreemSize.height <= 568) {object

       //设置页面升高的高度select

        self.view.transform=CGAffineTransformMakeTranslation(0, rect.origin.y-JWScreemSize.height);方法

    }

}

相关文章
相关标签/搜索