save the height value if the normal keybaord is open and the height if the keybaird is not open, then open the emojis, compare it with the 2 Values and if it is not fit, then you know that the emoji keyboard is open and then you can calculate the top value new.