Skip to content

Commit

Permalink
formatting fixes + rename toggle_touchpad
Browse files Browse the repository at this point in the history
  • Loading branch information
aarron-lee committed Nov 26, 2023
1 parent a7c6c3b commit c5cf272
Show file tree
Hide file tree
Showing 2 changed files with 214 additions and 155 deletions.
14 changes: 6 additions & 8 deletions main.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,13 @@ async def rgb_color(self, controller: str, red, blue, green, brightness):

async def rgb_on(self, controller: str):
controller_code = controller_enums.Controller[controller].value
rgb_on_command = legion_configurator.legion_configurator.create_rgb_on_off_command(controller_code, True)
rgb_on_command = legion_configurator.create_rgb_on_off_command(controller_code, True)
decky_plugin.logger.info(rgb_on_command)
legion_configurator.send_command(rgb_on_command)

async def rgb_off(self, controller: str):
controller_code = controller_enums.Controller[controller].value
rgb_off_command = legion_configurator.legion_configurator.create_rgb_on_off_command(controller_code, False)
rgb_off_command = legion_configurator.create_rgb_on_off_command(controller_code, False)
decky_plugin.logger.info(rgb_off_command)
legion_configurator.send_command(rgb_off_command)

Expand All @@ -78,12 +78,7 @@ async def remap_button(self, button: str, action: str):

legion_configurator.send_command(remap_command)



async def log_info(self, info):
logging.info(info)

async def touchpad_toggle(self, enable: bool):
async def set_touchpad(self, enable: bool):
t_toggle = legion_configurator.create_touchpad_command(enable)
decky_plugin.logger.info(t_toggle)

Expand Down Expand Up @@ -113,3 +108,6 @@ async def _migration(self):
decky_plugin.migrate_runtime(
os.path.join(decky_plugin.DECKY_HOME, "template"),
os.path.join(decky_plugin.DECKY_USER_HOME, ".local", "share", "decky-template"))

async def log_info(self, info):
logging.info(info)
Loading

0 comments on commit c5cf272

Please sign in to comment.