-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathF1AltEnterF12.rb
More file actions
22 lines (18 loc) · 828 Bytes
/
F1AltEnterF12.rb
File metadata and controls
22 lines (18 loc) · 828 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#==============================================================================
# Chainsawkitten's Disable F1, Alt+Enter, F12 v1.1
#------------------------------------------------------------------------------
# Disable the use of F1, Alt+Enter and F12 by registering a hook which consumes
# keypress events as well as setting the keyboard state.
#==============================================================================
module CskDisable
# Whether to disable F1. 0 = enable, 1 = disable.
DISABLE_F1 = 1
# Whether to disable F12. 0 = enable, 1 = disable.
DISABLE_F12 = 1
# Whether to disable Alt+Enter. 0 = enable, 1 = disable.
DISABLE_ALT_ENTER = 1
end
Win32API.new("System/F1AltEnterF12", "hook", "III", "").call(
CskDisable::DISABLE_F1,
CskDisable::DISABLE_F12,
CskDisable::DISABLE_ALT_ENTER)