鼠标模拟操作:
需要用到ActionChains()类:
1、鼠标悬停:move_to_element()
2、双击:double_click()
3、右击:context_click()
4、按住鼠标左键不松开:click_and_hold()
5、按照坐标移动鼠标:move_by_offset(x,y)
6、拖拽元素移动一定像素点:drag_and_drop_by_offset(ele,x,y)
7、把元素移动到另一元素上:drag_and_drop()
8、把光标移动到距离某个元素左上角一定像素点的位置:move_to_element_with_offset()
firefox浏览器有一个测量距离像素点的插件:Measure-it
9、按下某个键:key_down()
9、松开某个键:key_up()
10、松开鼠标:release()
11、点击:click()
12、输入:send_keys()
13、执行上述操作:perform()