i know that pure java can't disable alt+tab,i must use JNI with C
language. i have a pile of codes to disable the alt+tab in C but i do
not know how to do it in JNI...i have looked at the tutorial in
java.sun,but i do not understand how it works.can anyone help?thanks
in advance...
these are my codes in C:
Private Declare Function SystemParametersInfo Lib "user32" _
Alias "SystemParametersInfoA" (ByVal uAction As Long, _
ByVal uParam As Long, lpvParam As Any, ByVal fuWinIni As Long) As
Long
Private Const SPI_SCREENSAVERRUNNING = 97
Dim ret As Integer
Dim pOld As Boolean
Private Sub Form_Load()
'The line below calls the function and passes
'the constant and TRUE to fool Windows into thinking
'the screensaver is running and FALSE to do the opposite...
ret = SystemParametersInfo(SPI_SCREENSAVERRUNNING, True, pOld, 0)
End Sub
Private Sub Form_Unload(Cancel As Integer)
'NOTE: THIS MUST BE SET TO FALSE WHEN
'THE FORM OR APP CLOSES
'If you do not set it to false, these keys will not work
'with any app, or with anything in the Windows Environment...
ret = SystemParametersInfo(SPI_SCREENSAVERRUNNING, False, pOld, 0)
End Sub