selenium+python3 鼠标事件

1、鼠标右击

ActionChains(driver).contest_click(right_click).perform()

2、鼠标悬停

ActionChains(driver).move_to_element(above).perform()

3、鼠标双击

ActionChains(driver).double_click(double_click).perform()

4、鼠标拖放操作

drag_and_drop(source,target)

source:鼠标拖动的源元素

target:鼠标释放的目标元素

 
posted @ 2017-03-02 16:37  chen狗蛋儿  阅读(1514)  评论(0编辑  收藏  举报