![在 gsettings 中自定义睡眠按钮选项没有任何作用 17.04](https://linux22.com/image/894415/%E5%9C%A8%20gsettings%20%E4%B8%AD%E8%87%AA%E5%AE%9A%E4%B9%89%E7%9D%A1%E7%9C%A0%E6%8C%89%E9%92%AE%E9%80%89%E9%A1%B9%E6%B2%A1%E6%9C%89%E4%BB%BB%E4%BD%95%E4%BD%9C%E7%94%A8%2017.04.png)
我使用 dconf-editor 编辑 org.gnome.settings-daemon.plugins.power 中的睡眠按钮选项,但它什么也没做,我所要做的就是用关闭显示器来替换让 Ubuntu 进入睡眠状态的所有内容,而这个过程的最后一步是更改设置,我知道问题不在于 dconf-editor,因为 gsettings 显示设置已更改为我想要的。
我的键盘是一个旧的廉价 emachines 键盘,使用 ps/2 端口,如果有区别的话。
澄清:我想要的是将按钮睡眠设置为“空白”,但当我将其设置为“空白”时,按下睡眠键时它不会使屏幕变黑,而是会暂停计算机
cat /etc/systemd/logind.conf 的输出:
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# Entries in this file show the compile time defaults.
# You can change settings by editing this file.
# Defaults can be restored by simply deleting this file.
#
# See logind.conf(5) for details.
[Login]
#NAutoVTs=6
#ReserveVT=6
#KillUserProcesses=no
#KillOnlyUsers=
#KillExcludeUsers=root
#InhibitDelayMaxSec=5
#HandlePowerKey=poweroff
HandleSuspendKey=ignore
#HandleHibernateKey=hibernate
#HandleLidSwitch=suspend
#HandleLidSwitchDocked=ignore
#PowerKeyIgnoreInhibited=no
#SuspendKeyIgnoreInhibited=no
#HibernateKeyIgnoreInhibited=no
#LidSwitchIgnoreInhibited=yes
#HoldoffTimeoutSec=30s
#IdleAction=ignore
#IdleActionSec=30min
#RuntimeDirectorySize=10%
#RemoveIPC=yes
#InhibitorsMax=8192
#SessionsMax=8192
#UserTasksMax=33%