scroll_mouse.py 566 Bytes
Newer Older
Robert Poienar's avatar
Robert Poienar committed
1 2 3 4 5 6 7 8 9 10 11 12
from altunityrunner.commands.command_returning_alt_elements import CommandReturningAltElements
import time
class ScrollMouse(CommandReturningAltElements):
    def __init__(self, socket,requestSeparator,requestEnd, speed, duration):
        super().__init__(socket,requestSeparator,requestEnd)
        self.speed=speed
        self.duration=duration
    
    def execute(self):
        print ('Scroll mouse with: ' + str(self.speed))
        data = self.send_data(self.create_command('scrollMouse', self.speed, self.duration ))
        return self.handle_errors(data)