def _inplace_elem(deployer, *args,**kwargs): deployer(*args,**kwargs) time.sleep(self.wait_short) self._n_elems+=1 deployed_elem = workspace_element(self.driver,self._n_elems-1) draggable = deployed_elem if self.driver.name == 'phantomjs' else element_rectangle(deployed_elem) chains = wd.ActionChains(self.driver) chains.drag_and_drop_by_offset(draggable,0,elem_offset_y*(self._n_elems-1)).perform() time.sleep(self.wait_short) return workspace_element(self.driver,self._n_elems-1)