fix bugs with emulation of mobile browser