问题描述
这是我的代码:
#This program will set the Throttlestop mode to Game,Performance or Cooling as specified.
#It uses the pyautogui and sys module.
import sys
import pyautogui
mode_name = sys.argv[1]
#All necessary postions
taskbar_icon = 1769,1049
throttlestop = 1770,900
game = 1800,785
performance = 1800,760
cooling = 1800,910
modes = {'performance':performance,'game':game,'cooling':cooling}
if mode_name in modes.keys():
pyautogui.moveto(taskbar_icon) #1
pyautogui.click()
pyautogui.moveto(throttlestop) #2
pyautogui.click(button='right')
pyautogui.moveto(modes[mode_name]) #3
pyautogui.click()
最后两行代码似乎不起作用。其他一切正常。我想从 Win+R 运行它(在创建 .bat 文件之后),并且在 IDE 中发生了同样的事情。我不明白为什么同样的功能会是情景。
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)