确定用户空闲时间

if(A_TimeIdlePhysical > 60000) { ; 60,000 milliseconds
    WinClose, ahk_class Chrome_WidgetWin_1
    MsgBox, Google Chrome was closed due to user inactivity.
}

这种检查可以定期进行,例如使用 SetTimer。