2011-10-16 21:01:42 +00:00
|
|
|
# $FreeBSD$
|
|
|
|
#
|
|
|
|
# PowerPC Apple specific devd events
|
|
|
|
|
|
|
|
# Keyboard power key
|
|
|
|
notify 0 {
|
|
|
|
match "system" "PMU";
|
|
|
|
match "subsystem" "Button";
|
|
|
|
action "shutdown -p now";
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2011-12-05 14:13:21 +00:00
|
|
|
# PowerBook and iBook lid close.
|
2011-12-05 00:12:10 +00:00
|
|
|
notify 0 {
|
|
|
|
match "system" "PMU";
|
|
|
|
match "subsystem" "lid";
|
|
|
|
match "type" "close";
|
|
|
|
action "shutdown -p now";
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2012-02-26 13:45:25 +00:00
|
|
|
# The next blocks enable brightness hotkeys that can be found on Apple laptops
|
|
|
|
notify 0 {
|
|
|
|
match "system" "PMU";
|
|
|
|
match "subsystem" "keys";
|
|
|
|
match "type" "brightness";
|
|
|
|
match "notify" "down";
|
|
|
|
action "sysctl dev.backlight.0.level=\
|
|
|
|
$(expr `sysctl -n dev.backlight.0.level` - 10)";
|
|
|
|
};
|
|
|
|
|
|
|
|
notify 0 {
|
|
|
|
match "system" "PMU";
|
|
|
|
match "subsystem" "keys";
|
|
|
|
match "type" "brightness";
|
|
|
|
match "notify" "up";
|
|
|
|
action "sysctl dev.backlight.0.level=\
|
|
|
|
$(expr `sysctl -n dev.backlight.0.level` + 10)";
|
|
|
|
};
|
|
|
|
|
|
|
|
|
2011-10-16 21:01:42 +00:00
|
|
|
# The next blocks enable volume hotkeys that can be found on Apple laptops
|
|
|
|
notify 0 {
|
|
|
|
match "system" "PMU";
|
|
|
|
match "subsystem" "keys";
|
|
|
|
match "type" "mute";
|
2022-03-14 08:36:58 +00:00
|
|
|
action "mixer vol.mute=^";
|
2011-10-16 21:01:42 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
notify 0 {
|
|
|
|
match "system" "PMU";
|
|
|
|
match "subsystem" "keys";
|
|
|
|
match "type" "volume";
|
|
|
|
match "notify" "down";
|
2022-03-13 13:13:28 +00:00
|
|
|
action "mixer vol.volume=-10";
|
2011-10-16 21:01:42 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
notify 0 {
|
|
|
|
match "system" "PMU";
|
|
|
|
match "subsystem" "keys";
|
|
|
|
match "type" "volume";
|
|
|
|
match "notify" "up";
|
2022-03-13 13:13:28 +00:00
|
|
|
action "mixer vol.volume=+10";
|
2011-10-16 21:01:42 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
# Eject key
|
|
|
|
notify 0 {
|
|
|
|
match "system" "PMU";
|
|
|
|
match "subsystem" "keys";
|
|
|
|
match "type" "eject";
|
|
|
|
action "camcontrol eject cd0";
|
|
|
|
};
|
|
|
|
|
2014-10-12 19:12:48 +00:00
|
|
|
# Equivalent to the ACPI/ACAD notify
|
|
|
|
notify 10 {
|
|
|
|
match "system" "PMU";
|
|
|
|
match "subsystem" "POWER";
|
|
|
|
match "type" "ACLINE";
|
2018-06-11 22:48:34 +00:00
|
|
|
action "service power_profile $notify";
|
2014-11-18 16:31:00 +00:00
|
|
|
};
|