예제 #1
0
        public static uint GetLastInputTime()
        {
            LastInputInfo info = new LastInputInfo();

            info.cbSize = Marshal.SizeOf(info);

            if (!NativeMethods.GetLastInputInfo(ref info))
            {
                throw new Win32Exception(Marshal.GetLastWin32Error());
            }

            return(info.dwTime);
        }
예제 #2
0
 private static extern bool GetLastInputInfo(ref LastInputInfo lastInputInfo);