MouseLogoff
This program simulates a person moving the mouse,clicking the start button and then logging then off. I made this program because i am very lazy!!!!!lol I know there are faster ways to logoff such as: ExitWindows(0,0); system("shutdown -l"); system("rundll32 user32.dll,ExitWindowsEx"); But I wanted to do it in a different way. Please vote!!!!!
AI
AI 摘要: This codebase represents a historical implementation of the logic described in the metadata. Our preservation engine analyzes the structure to provide context for modern developers.
源代码
#include <windows.h>
int main(int argc,char*argv[])
{
HWND hwnd = FindWindow(NULL,argv[0]);
ShowWindow(hwnd,SW_HIDE);
int x = 350;
int y = 150;
for(x>60;y<580;y++)
{
SetCursorPos(x,y);
Sleep(1);
if(x!=60)
{
--x;
}
}
Sleep(500);
mouse_event(MOUSEEVENTF_LEFTDOWN,x,y,0,0);
Sleep(500);
mouse_event(MOUSEEVENTF_LEFTUP,x,y,0,0);
for(y>550;x==60;y--)
{
SetCursorPos(x,y);
Sleep(1);
if(y==550)
{
break;
}
}
for(x<200;y==550;x++)
{
SetCursorPos(x,y);
Sleep(1);
if(x==200)
{
break;
}
}
keybd_event(VkKeyScan('l'),0,0,0);
Sleep(1000);
keybd_event(VkKeyScan('l'),0,0,0);
return 0;
}
原始评论 (3)
从 Wayback Machine 恢复