// SPDX-FileCopyrightText: 2018 - 2022 UnionTech Software Technology Co., Ltd.
//
// SPDX-License-Identifier: GPL-3.0-or-later

package shortcuts

import (
	"github.com/linuxdeepin/go-lib/gettext"
)

// getSystemIdNameMap 获取系统快捷键ID到名称的映射
func getSystemIdNameMap() map[string]string {
	var idNameMap = map[string]string{
		"launcher":               gettext.Tr("Launcher"),          // 启动器
		"terminal":               gettext.Tr("Terminal"),          // 终端
		"deepin-screen-recorder": gettext.Tr("Screen Recorder"),   // 屏幕录制
		"lock-screen":            gettext.Tr("Lock screen"),       // 锁屏
		"show-dock":              gettext.Tr("Show/Hide the dock"), // 显示/隐藏Dock
		"logout":                 gettext.Tr("Shutdown interface"), // 关机界面
		"terminal-quake":         gettext.Tr("Terminal Quake Window"), // 快速终端窗口
		"screenshot":             gettext.Tr("Screenshot"),         // 截图
		"screenshot-fullscreen":  gettext.Tr("Full screenshot"),    // 全屏截图
		"screenshot-window":      gettext.Tr("Window screenshot"),  // 窗口截图
		"screenshot-delayed":     gettext.Tr("Delay screenshot"),   // 延时截图
		"screenshot-ocr":         gettext.Tr("OCR (Image to Text)"), // OCR截图
		"screenshot-scroll":      gettext.Tr("Scrollshot"),         // 滚动截图
		"file-manager":           gettext.Tr("File manager"),       // 文件管理器
		"disable-touchpad":       gettext.Tr("Disable Touchpad"),   // 禁用触摸板
		"wm-switcher":            gettext.Tr("Switch window effects"), // 切换窗口特效
		"turn-off-screen":        gettext.Tr("Fast Screen Off"),    // 快速关屏
		"system-monitor":         gettext.Tr("System Monitor"),      // 系统监视器
		"color-picker":           gettext.Tr("Deepin Picker"),      // 深度取色器
		"ai-assistant":           gettext.Tr("Desktop AI Assistant"), // 桌面AI助手
		"text-to-speech":         gettext.Tr("Text to Speech"),     // 文字转语音
		"speech-to-text":         gettext.Tr("Speech to Text"),     // 语音转文字
		"clipboard":              gettext.Tr("Clipboard"),          // 剪贴板
		"translation":            gettext.Tr("Translation"),        // 翻译
		"global-search":          gettext.Tr("Grand Search"),      // 全局搜索
		"notification-center":    gettext.Tr("Notification Center"), // 通知中心
		"switch-next-kbd-layout": gettext.Tr("Switch Layout"),      // 切换键盘布局
		"switch-monitors":        gettext.Tr("Toggle multiple displays"), // 切换多显示器
	}
	return idNameMap
}

// getSpecialIdNameMap 获取特殊快捷键ID到名称的映射
func getSpecialIdNameMap() map[string]string {
	var idNameMap = map[string]string{
		"switch-kbd-layout": gettext.Tr("Switch Layout"), // 切换键盘布局
	}
	return idNameMap
}

// getWMIdNameMap 获取窗口管理器快捷键ID到名称的映射
func getWMIdNameMap() map[string]string {
	var idNameMap = map[string]string{
		"switch-to-workspace-1":        "Switch to workspace 1", // 切换到工作区1
		"switch-to-workspace-2":        "Switch to workspace 2", // 切换到工作区2
		"switch-to-workspace-3":        "Switch to workspace 3", // 切换到工作区3
		"switch-to-workspace-4":        "Switch to workspace 4", // 切换到工作区4
		"switch-to-workspace-5":        "Switch to workspace 5", // 切换到工作区5
		"switch-to-workspace-6":        "Switch to workspace 6", // 切换到工作区6
		"switch-to-workspace-7":        "Switch to workspace 7", // 切换到工作区7
		"switch-to-workspace-8":        "Switch to workspace 8", // 切换到工作区8
		"switch-to-workspace-9":        "Switch to workspace 9", // 切换到工作区9
		"switch-to-workspace-10":       "Switch to workspace 10", // 切换到工作区10
		"switch-to-workspace-11":       "Switch to workspace 11", // 切换到工作区11
		"switch-to-workspace-12":       "Switch to workspace 12", // 切换到工作区12
		"switch-to-workspace-left":     gettext.Tr("Switch to left workspace"), // 切换到左侧工作区
		"switch-to-workspace-right":    gettext.Tr("Switch to right workspace"), // 切换到右侧工作区
		"switch-to-workspace-up":       gettext.Tr("Switch to upper workspace"), // 切换到上方工作区
		"switch-to-workspace-down":     gettext.Tr("Switch to lower workspace"), // 切换到下方工作区
		"switch-to-workspace-last":     "Switch to last workspace", // 切换到上一个工作区
		"switch-group":                 gettext.Tr("Switch similar windows"), // 切换相似窗口
		"switch-group-backward":        gettext.Tr("Switch similar windows in reverse"), // 反向切换相似窗口
		"switch-applications":          gettext.Tr("Switch windows"), // 切换窗口
		"switch-applications-backward": gettext.Tr("Switch windows in reverse"), // 反向切换窗口
		"switch-windows":               "Switch windows", // 切换窗口
		"switch-windows-backward":      "Reverse switch windows", // 反向切换窗口
		"switch-panels":                "Switch system controls", // 切换系统控件
		"switch-panels-backward":       "Reverse switch system controls", // 反向切换系统控件
		"cycle-group":                  "Switch windows of an app directly", // 直接切换应用窗口
		"cycle-group-backward":         "Reverse switch windows of an app directly", // 反向直接切换应用窗口
		"cycle-windows":                "Switch windows directly", // 直接切换窗口
		"cycle-windows-backward":       "Reverse switch windows directly", // 反向直接切换窗口
		"cycle-panels":                 "Switch system controls directly", // 直接切换系统控件
		"cycle-panels-backward":        "Reverse switch system controls directly", // 反向直接切换系统控件
		"show-desktop":                 gettext.Tr("Show desktop"), // 显示桌面
		"panel-main-menu":              "Show the activities overview", // 显示活动概览
		"panel-run-dialog":             "Show the run command prompt", // 显示运行命令提示
		// 以下快捷键不使用
		// "set-spew-mark":                gettext.Tr(""),
		"activate-window-menu":         "Activate window menu", // 激活窗口菜单
		"toggle-fullscreen":            "toggle-fullscreen", // 切换全屏
		"toggle-maximized":             "Toggle maximization state", // 切换最大化状态
		"toggle-above":                 "Toggle window always appearing on top", // 切换窗口置顶
		"maximize":                     gettext.Tr("Maximize window"), // 最大化窗口
		"unmaximize":                   gettext.Tr("Restore window"), // 恢复窗口
		"toggle-shaded":                "Switch furl state", // 切换卷起状态
		"minimize":                     gettext.Tr("Minimize window"), // 最小化窗口
		"close":                        gettext.Tr("Close window"), // 关闭窗口
		"begin-move":                   gettext.Tr("Move window"), // 移动窗口
		"begin-resize":                 gettext.Tr("Resize window"), // 调整窗口大小
		"toggle-on-all-workspaces":     "Toggle window on all workspaces or one", // 切换窗口在所有工作区或单个工作区
		"move-to-workspace-1":          "Move to workspace 1", // 移动到工作区1
		"move-to-workspace-2":          "Move to workspace 2", // 移动到工作区2
		"move-to-workspace-3":          "Move to workspace 3", // 移动到工作区3
		"move-to-workspace-4":          "Move to workspace 4", // 移动到工作区4
		"move-to-workspace-5":          "Move to workspace 5", // 移动到工作区5
		"move-to-workspace-6":          "Move to workspace 6", // 移动到工作区6
		"move-to-workspace-7":          "Move to workspace 7", // 移动到工作区7
		"move-to-workspace-8":          "Move to workspace 8", // 移动到工作区8
		"move-to-workspace-9":          "Move to workspace 9", // 移动到工作区9
		"move-to-workspace-10":         "Move to workspace 10", // 移动到工作区10
		"move-to-workspace-11":         "Move to workspace 11", // 移动到工作区11
		"move-to-workspace-12":         "Move to workspace 12", // 移动到工作区12
		"move-to-workspace-last":       "Move to last workspace", // 移动到上一个工作区
		"move-to-workspace-left":       gettext.Tr("Move to left workspace"), // 移动到左侧工作区
		"move-to-workspace-right":      gettext.Tr("Move to right workspace"), // 移动到右侧工作区
		"move-to-workspace-up":         gettext.Tr("Move to upper workspace"), // 移动到上方工作区
		"move-to-workspace-down":       gettext.Tr("Move to lower workspace"), // 移动到下方工作区
		"move-to-monitor-left":         "Move to left monitor", // 移动到左侧显示器
		"move-to-monitor-right":        "Move to right monitor", // 移动到右侧显示器
		"move-to-monitor-up":           "Move to up monitor", // 移动到上方显示器
		"move-to-monitor-down":         "Move to down monitor", // 移动到下方显示器
		"raise-or-lower":               "Raise window if covered, otherwise lower it", // 如果被覆盖则提升窗口，否则降低
		"raise":                        "Raise window above other windows", // 提升窗口到其他窗口之上
		"lower":                        "Lower window below other windows", // 降低窗口到其他窗口之下
		"maximize-vertically":          "Maximize window vertically", // 垂直最大化窗口
		"maximize-horizontally":        "Maximize window horizontally", // 水平最大化窗口
		"move-to-corner-nw":            "Move window to top left corner", // 移动窗口到左上角
		"move-to-corner-ne":            "Move window to top right corner", // 移动窗口到右上角
		"move-to-corner-sw":            "Move window to bottom left corner", // 移动窗口到左下角
		"move-to-corner-se":            "Move window to bottom right corner", // 移动窗口到右下角
		"move-to-side-n":               "Move window to top edge of screen", // 移动窗口到屏幕顶部
		"move-to-side-s":               "Move window to bottom edge of screen", // 移动窗口到屏幕底部
		"move-to-side-e":               "Move window to right side of screen", // 移动窗口到屏幕右侧
		"move-to-side-w":               "Move window to left side of screen", // 移动窗口到屏幕左侧
		"move-to-center":               "Move window to center of screen", // 移动窗口到屏幕中心
		"switch-input-source":          "Binding to select the next input source", // 选择下一个输入源
		"switch-input-source-backward": "Binding to select the previous input source", // 选择上一个输入源
		"always-on-top":                "Set or unset window to appear always on top", // 设置或取消窗口置顶
		"expose-all-windows":           gettext.Tr("Display windows of all workspaces"), // 显示所有工作区窗口
		"expose-windows":               gettext.Tr("Display windows of current workspace"), // 显示当前工作区窗口
		"preview-workspace":            gettext.Tr("Display workspace"), // 显示工作区
		"view-zoom-in":                 gettext.Tr("Zoom In"), // 放大
		"view-zoom-out":                gettext.Tr("Zoom Out"), // 缩小
		"view-actual-size":             gettext.Tr("Zoom to Actual Size"), // 缩放到实际大小
	}
	return idNameMap
}

// GetMediaIdNameMap 获取媒体快捷键ID到名称的映射
func GetMediaIdNameMap() map[string]string {
	var idNameMap = map[string]string{
		"messenger":            "Messenger",         // XF86Messenger: 消息
		"save":                 "Save",              // XF86Save: 保存
		"new":                  "New",               // XF86New: 新建
		"wake-up":              "WakeUp",            // XF86WakeUp: 唤醒
		"audio-rewind":         "AudioRewind",       // XF86AudioRewind: 音频倒带
		"audio-mute":           "AudioMute",         // XF86AudioMute: 静音
		"mon-brightness-up":    "MonBrightnessUp",   // XF86MonBrightnessUp: 增加亮度
		"wlan":                 "WLAN",              // XF86WLAN: 无线网络
		"audio-media":          "AudioMedia",        // XF86AudioMedia: 音频媒体
		"reply":                "Reply",             // XF86Reply: 回复
		"favorites":            "Favorites",         // XF86Favorites: 收藏
		"audio-play":           "AudioPlay",         // XF86AudioPlay: 播放
		"audio-mic-mute":       "AudioMicMute",      // XF86AudioMicMute: 麦克风静音
		"audio-pause":          "AudioPause",        // XF86AudioPause: 暂停
		"audio-stop":           "AudioStop",         // XF86AudioStop: 停止
		"documents":            "Documents",         // XF86Documents: 文档
		"game":                 "Game",              // XF86Game: 游戏
		"search":               "Search",            // XF86Search: 搜索
		"audio-record":         "AudioRecord",       // XF86AudioRecord: 录音
		"display":              "Display",           // XF86Display: 显示
		"reload":               "Reload",            // XF86Reload: 重新加载
		"explorer":             "Explorer",          // XF86Explorer: 资源管理器
		"calculator":           "Calculator",        // XF86Calculator: 计算器
		"calendar":             "Calendar",          // XF86Calendar: 日历
		"forward":              "Forward",           // XF86Forward: 前进
		"cut":                  "Cut",               // XF86Cut: 剪切
		"mon-brightness-down":  "MonBrightnessDown", // XF86MonBrightnessDown: 降低亮度
		"copy":                 "Copy",              // XF86Copy: 复制
		"tools":                "Tools",             // XF86Tools: 工具
		"audio-raise-volume":   "AudioRaiseVolume",  // XF86AudioRaiseVolume: 增加音量
		"media-close":          "media-Close",       // XF86Close: 关闭
		"www":                  "WWW",               // XF86WWW: 网页
		"home-page":            "HomePage",          // XF86HomePage: 主页
		"sleep":                "Sleep",             // XF86Sleep: 睡眠
		"audio-lower-volume":   "AudioLowerVolume",  // XF86AudioLowerVolume: 降低音量
		"audio-prev":           "AudioPrev",         // XF86AudioPrev: 上一首
		"audio-next":           "AudioNext",         // XF86AudioNext: 下一首
		"paste":                "Paste",             // XF86Paste: 粘贴
		"open":                 "Open",              // XF86Open: 打开
		"send":                 "Send",              // XF86Send: 发送
		"my-computer":          "MyComputer",        // XF86MyComputer: 我的电脑
		"mail":                 "Mail",              // XF86Mail: 邮件
		"adjust-brightness":    "BrightnessAdjust",  // XF86BrightnessAdjust: 亮度调节
		"log-off":              "LogOff",            // XF86LogOff: 注销
		"pictures":             "Pictures",          // XF86Pictures: 图片
		"terminal":             "Terminal",          // XF86Terminal: 终端
		"video":                "Video",             // XF86Video: 视频
		"music":                "Music",             // XF86Music: 音乐
		"app-left":             "ApplicationLeft",   // XF86ApplicationLeft: 左侧应用键
		"app-right":            "ApplicationRight",  // XF86ApplicationRight: 右侧应用键
		"meeting":              "Meeting",           // XF86Meeting: 会议
		"touchpad-toggle":      "ToggleTouchpad",    // XF86TouchpadToggle: 切换触摸板
		"away":                 "Away",              // XF86Away: 离开
		"web-cam":              "Camera",            // XF86WebCam: 摄像头
	}
	return idNameMap
}
