Beispiel #1
0
 /// <summary>
 ///     アクティブウィンドウが変わったら最前面を取り直す.
 /// </summary>
 private void shellHook_WindowActivated(object sender, ShellHookEventArgs e)
 {
     User.SetWindowPos(Handle, new IntPtr(-1) /* HWND_TOPMOST */, 0, 0, 0, 0,
                       SetWindowPosFlag.NoActivate | SetWindowPosFlag.NoMove | SetWindowPosFlag.NoSize);
 }
Beispiel #2
0
 private void shellHook_WindowActivated(object sender, ShellHookEventArgs e)
 {
     Topmost = false;
     Topmost = true;
 }