mirror of
https://github.com/linuxdeepin/dde-dock.git
synced 2025-06-04 17:33:05 +00:00
keybinding: don't show deepin-translator if not installed
tower: https://tower.im/projects/4467e3e08ad941bd8a450dbbc65c20c5/todos/1c758fd1955c41fe8657fceac2d292cf/ Change-Id: Ie194399c5de2c94eab61603684730468cc74339e
This commit is contained in:
parent
ffe9c0e7c7
commit
b7120bedfa
@ -24,6 +24,7 @@ package keybinding
|
||||
import (
|
||||
"dbus/com/deepin/daemon/inputdevices"
|
||||
"github.com/BurntSushi/xgbutil/keybind"
|
||||
dutils "pkg.linuxdeepin.com/lib/utils"
|
||||
"strconv"
|
||||
"strings"
|
||||
)
|
||||
@ -566,6 +567,8 @@ func isKeySupported(key string) bool {
|
||||
switch key {
|
||||
case "disable-touchpad":
|
||||
return isTouchpadExist()
|
||||
case "deepin-translator":
|
||||
return dutils.IsFileExist("/usr/bin/deepin-translator")
|
||||
}
|
||||
|
||||
return true
|
||||
|
Loading…
x
Reference in New Issue
Block a user