【鼠标增强】侧键激活窗口

使用方法:
按住鼠标左键,再按右键1次则记录当前窗口id,给鼠标侧键XButton1隐藏或唤醒窗口1使用
按住鼠标左键,再按右键2次则记录当前窗口id,给鼠标侧键XButton2隐藏或唤醒窗口2使用
对桌面或者任务栏,按住鼠标左键,再按右键1次或2次。则清除隐藏唤醒功能,恢复原键

【鼠标增强】侧键激活窗口

 

#if GetKeyState("LButton", "P")
RButton::
if (winc_presses > 0) {
winc_presses ++
Return
} winc_presses = 1
SetTimer KeyWinC18, -400
Return

KeyWinC18:
if (winc_presses = 1) {
	MouseGetPos,,,WinID
	WinGetClass, WinClass, ahk_id %WinID%
	if (WinClass="Progman") || (WinClass="Shell_TrayWnd")
		XButton1WinID:=""
	else
		XButton1WinID:=WinID
} else if (winc_presses = 2) {
	MouseGetPos,,,WinID
	WinGetClass, WinClass, ahk_id %WinID%
	if (WinClass="Progman") || (WinClass="Shell_TrayWnd")
		XButton2WinID:=""
	else
		XButton2WinID:=WinID
} winc_presses = 0
Return
#if

*$XButton1::
if (XButton1WinID="") {
	Send {XButton1}
 } else {
	if WinActive("ahk_id "XButton1WinID) {
		WinMinimize, ahk_id %XButton1WinID%
		WinActivate, ahk_class Shell_TrayWnd
	} else {
		WinRestore, ahk_id %XButton1WinID%
		WinActivate, ahk_id %XButton1WinID%
	}
} Return

*$XButton2::
if (XButton2WinID="") {
	Send {XButton2}
 } else {
	if WinActive("ahk_id "XButton2WinID) {
		WinMinimize, ahk_id %XButton2WinID%
		WinActivate, ahk_class Shell_TrayWnd
	} else {
		WinRestore, ahk_id %XButton2WinID%
		WinActivate, ahk_id %XButton2WinID%
	}
} Return

给TA捐赠
共{{data.count}}人
人已捐赠
其他

【LOL】显示攻击范围

2021-8-8 19:53:51

其他

210810.佳明 GARMIN Forerunner245神秘灰 三星定位智能手表

2021-8-10 6:56:09

4 条回复 A文章作者 M管理员
  1. 月下马

    帅呆了!!还有这种思路!受教啦!

  2. jameshoo007

    请问*$xbutton1,前面的*$是什么意思呀

  3. maxs

    好用。

  4. 青雀

个人中心
购物车
优惠劵
有新私信 私信列表
搜索