Ejemplo n.º 1
0
        // 폼 클로즈
        private void FormScreenSaver_FormClosing(object sender, FormClosingEventArgs e)
        {
            try
            {
                // 폼 애니메이션(아래서 위로)
                AnimateWindow(this.Handle, 500,
                              AnimateWindowFlags.AW_VER_NEGATIVE | AnimateWindowFlags.AW_HIDE);

                if (KeyboardHooking.WINDOWSTATUS == KeyboardHooking.SWP_HIDEWINDOW)
                {
                    KeyboardHooking.TaskBarShow(); // 작업표시줄 드러냄
                }

                // 키보드 후킹 해제
                KeyboardHooking.UnHookWindowsEx(intLLKey);
                KeyboardHooking.UnBlockCtrlAltDel();

                main.rcvRssi = default(int);

                this.Dispose();
            }
            catch (Exception ee)
            {
                Console.WriteLine("Saver Closing");
            }
        }
Ejemplo n.º 2
0
        private void frmMain_FormClosed(object sender, FormClosedEventArgs e)
        {
            try
            {
                // 키보드 후킹 해제
                KeyboardHooking.UnHookWindowsEx(intLLKey);

                System.Diagnostics.Process.GetCurrentProcess().Kill();
            }
            catch (Exception ea)
            {
                _log.write(ea.Message);
                frmMain._log.write(ea.StackTrace);
            }
        }